diff --git a/src/AtomUI.Base/AtomUI.Base.csproj b/src/AtomUI.Base/AtomUI.Base.csproj
index 589806da2..067acf797 100644
--- a/src/AtomUI.Base/AtomUI.Base.csproj
+++ b/src/AtomUI.Base/AtomUI.Base.csproj
@@ -15,6 +15,7 @@
+
diff --git a/src/AtomUI.Controls/Alert/AlertTheme.cs b/src/AtomUI.Controls/Alert/AlertTheme.cs
index 8c7cd7cf7..52be15870 100644
--- a/src/AtomUI.Controls/Alert/AlertTheme.cs
+++ b/src/AtomUI.Controls/Alert/AlertTheme.cs
@@ -172,7 +172,7 @@ internal class AlertTheme : BaseControlTheme
return descriptionLabel;
}
- protected override void BuildStyles()
+ protected override void BuildStyles()
{
BuildAlertTypeStyle();
BuildMessageLabelStyle();
diff --git a/src/AtomUI.Controls/AtomUI.Controls.csproj b/src/AtomUI.Controls/AtomUI.Controls.csproj
index f562db98d..46e649615 100644
--- a/src/AtomUI.Controls/AtomUI.Controls.csproj
+++ b/src/AtomUI.Controls/AtomUI.Controls.csproj
@@ -4,6 +4,7 @@
$(AtomUIDevelopTargetFramework);$(AtomUIProductionTargetFramework)
true
GeneratedFiles
+ AtomUI.Controls
diff --git a/src/AtomUI.Controls/GeneratedFiles/AtomUI.Generator/AtomUI.Generator.ControlThemeRegisterGenerator/ControlThemeRegister.g.cs b/src/AtomUI.Controls/GeneratedFiles/AtomUI.Generator/AtomUI.Generator.ControlThemeRegisterGenerator/ControlThemeRegister.g.cs
index cd03e710f..a18da3233 100644
--- a/src/AtomUI.Controls/GeneratedFiles/AtomUI.Generator/AtomUI.Generator.ControlThemeRegisterGenerator/ControlThemeRegister.g.cs
+++ b/src/AtomUI.Controls/GeneratedFiles/AtomUI.Generator/AtomUI.Generator.ControlThemeRegisterGenerator/ControlThemeRegister.g.cs
@@ -74,6 +74,9 @@
ThemeManager.Current.RegisterControlTheme(new AtomUI.Controls.NumericUpDownTheme());
ThemeManager.Current.RegisterControlTheme(new AtomUI.Controls.OptionButtonGroupTheme());
ThemeManager.Current.RegisterControlTheme(new AtomUI.Controls.OptionButtonTheme());
+ ThemeManager.Current.RegisterControlTheme(new AtomUI.Controls.PaginationNavItemTheme());
+ ThemeManager.Current.RegisterControlTheme(new AtomUI.Controls.PaginationNavTheme());
+ ThemeManager.Current.RegisterControlTheme(new AtomUI.Controls.PaginationTheme());
ThemeManager.Current.RegisterControlTheme(new AtomUI.Controls.PickerClearUpButtonTheme());
ThemeManager.Current.RegisterControlTheme(new AtomUI.Controls.PopupConfirmContainerTheme());
ThemeManager.Current.RegisterControlTheme(new AtomUI.Controls.PrimaryButtonTheme());
diff --git a/src/AtomUI.Controls/GeneratedFiles/AtomUI.Generator/AtomUI.Generator.TokenResourceKeyGenerator/ControlTokenRegister.g.cs b/src/AtomUI.Controls/GeneratedFiles/AtomUI.Generator/AtomUI.Generator.TokenResourceKeyGenerator/ControlTokenRegister.g.cs
index 071c01698..9a4704689 100644
--- a/src/AtomUI.Controls/GeneratedFiles/AtomUI.Generator/AtomUI.Generator.TokenResourceKeyGenerator/ControlTokenRegister.g.cs
+++ b/src/AtomUI.Controls/GeneratedFiles/AtomUI.Generator/AtomUI.Generator.TokenResourceKeyGenerator/ControlTokenRegister.g.cs
@@ -32,6 +32,7 @@
ThemeManager.Current.RegisterControlTokenType(typeof(AtomUI.Controls.NotificationToken));
ThemeManager.Current.RegisterControlTokenType(typeof(AtomUI.Controls.NumericUpDownToken));
ThemeManager.Current.RegisterControlTokenType(typeof(AtomUI.Controls.OptionButtonToken));
+ ThemeManager.Current.RegisterControlTokenType(typeof(AtomUI.Controls.PaginationToken));
ThemeManager.Current.RegisterControlTokenType(typeof(AtomUI.Controls.PopupConfirmToken));
ThemeManager.Current.RegisterControlTokenType(typeof(AtomUI.Controls.ProgressBarToken));
ThemeManager.Current.RegisterControlTokenType(typeof(AtomUI.Controls.RadioButtonToken));
diff --git a/src/AtomUI.Controls/GeneratedFiles/AtomUI.Generator/AtomUI.Generator.TokenResourceKeyGenerator/TokenResourceConst.g.cs b/src/AtomUI.Controls/GeneratedFiles/AtomUI.Generator/AtomUI.Generator.TokenResourceKeyGenerator/TokenResourceConst.g.cs
index 236065c99..bf9cb2206 100644
--- a/src/AtomUI.Controls/GeneratedFiles/AtomUI.Generator/AtomUI.Generator.TokenResourceKeyGenerator/TokenResourceConst.g.cs
+++ b/src/AtomUI.Controls/GeneratedFiles/AtomUI.Generator/AtomUI.Generator.TokenResourceKeyGenerator/TokenResourceConst.g.cs
@@ -504,6 +504,24 @@ namespace AtomUI.Theme.Styling
public static readonly TokenResourceKey PaddingSM = new TokenResourceKey("OptionButton.PaddingSM");
}
+ public static class PaginationTokenKey
+ {
+ public static readonly TokenResourceKey InputOutlineOffset = new TokenResourceKey("Pagination.InputOutlineOffset");
+ public static readonly TokenResourceKey ItemActiveBg = new TokenResourceKey("Pagination.ItemActiveBg");
+ public static readonly TokenResourceKey ItemActiveBgDisabled = new TokenResourceKey("Pagination.ItemActiveBgDisabled");
+ public static readonly TokenResourceKey ItemActiveColorDisabled = new TokenResourceKey("Pagination.ItemActiveColorDisabled");
+ public static readonly TokenResourceKey ItemBg = new TokenResourceKey("Pagination.ItemBg");
+ public static readonly TokenResourceKey ItemInputBg = new TokenResourceKey("Pagination.ItemInputBg");
+ public static readonly TokenResourceKey ItemLinkBg = new TokenResourceKey("Pagination.ItemLinkBg");
+ public static readonly TokenResourceKey ItemSize = new TokenResourceKey("Pagination.ItemSize");
+ public static readonly TokenResourceKey ItemSizeSM = new TokenResourceKey("Pagination.ItemSizeSM");
+ public static readonly TokenResourceKey MiniOptionsSizeChangerTop = new TokenResourceKey("Pagination.MiniOptionsSizeChangerTop");
+ public static readonly TokenResourceKey PaginationItemPaddingInline = new TokenResourceKey("Pagination.PaginationItemPaddingInline");
+ public static readonly TokenResourceKey PaginationMiniOptionsMarginInline = new TokenResourceKey("Pagination.PaginationMiniOptionsMarginInline");
+ public static readonly TokenResourceKey PaginationMiniQuickJumperInputWidth = new TokenResourceKey("Pagination.PaginationMiniQuickJumperInputWidth");
+ public static readonly TokenResourceKey PaginationSlashMarginInline = new TokenResourceKey("Pagination.PaginationSlashMarginInline");
+ }
+
public static class PopupConfirmTokenKey
{
public static readonly TokenResourceKey ButtonContainerMargin = new TokenResourceKey("PopupConfirm.ButtonContainerMargin");
diff --git a/src/AtomUI.Controls/Pagination/Pagination.cs b/src/AtomUI.Controls/Pagination/Pagination.cs
new file mode 100644
index 000000000..faa29c3cb
--- /dev/null
+++ b/src/AtomUI.Controls/Pagination/Pagination.cs
@@ -0,0 +1,204 @@
+using System.Diagnostics;
+using AtomUI.IconPkg.AntDesign;
+using AtomUI.Theme;
+using AtomUI.Theme.Utils;
+using Avalonia;
+using Avalonia.Controls;
+using Avalonia.Controls.Primitives;
+using Avalonia.Controls.Templates;
+using Avalonia.LogicalTree;
+
+namespace AtomUI.Controls;
+
+public enum PaginationAlign
+{
+ Start,
+ Center,
+ End
+}
+
+public class Pagination : TemplatedControl,
+ ISizeTypeAware,
+ IMotionAwareControl,
+ IControlSharedTokenResourcesHost
+{
+ public const int DefaultPageSize = 10;
+ public const int DefaultCurrentPage = 1;
+ #region 公共属性定义
+
+ public static readonly StyledProperty AlignProperty =
+ AvaloniaProperty.Register