using System;
using Avalonia;
using Avalonia.Controls;
namespace ControlCatalog.Controls
{
///
/// The standard catalog page: a scrolling page whose header is shown by the shell navigation bar and whose
/// is rendered above the content. Pages stack s inside it.
/// A page whose content scrolls itself sets ScrollViewer.VerticalScrollBarVisibility="Disabled", so the
/// content gets the page height instead of growing to its full extent.
///
public class SamplePage : ContentPage
{
public static readonly StyledProperty DescriptionProperty =
AvaloniaProperty.Register(nameof(Description));
///
/// One or two sentences saying what the control is for. Shown under the page title.
///
public string? Description
{
get => GetValue(DescriptionProperty);
set => SetValue(DescriptionProperty, value);
}
// Pages derive from this class, and a theme is looked up by the exact type.
protected override Type StyleKeyOverride => typeof(SamplePage);
}
}