diff --git a/src/MudBlazor/Base/MudBaseButton.cs b/src/MudBlazor/Base/MudBaseButton.cs index 32a8763f2ee..82fc93d215b 100644 --- a/src/MudBlazor/Base/MudBaseButton.cs +++ b/src/MudBlazor/Base/MudBaseButton.cs @@ -75,7 +75,7 @@ public abstract class MudBaseButton : MudComponentBase public string? Rel { get; set; } /// - /// Whether the user can interact with this button. + /// Allows the user to interact with this button. /// /// /// Defaults to false. @@ -95,7 +95,7 @@ public abstract class MudBaseButton : MudComponentBase public string? Title { get; set; } /// - /// Whether a click event is bubbled up to the parent component. + /// Allows the click event to bubble up to the parent component. /// /// /// Defaults to false. @@ -105,7 +105,7 @@ public abstract class MudBaseButton : MudComponentBase public bool ClickPropagation { get; set; } /// - /// Whether a shadow is displayed. + /// Displays a shadow. /// /// /// Defaults to true. @@ -115,7 +115,7 @@ public abstract class MudBaseButton : MudComponentBase public bool DropShadow { get; set; } = true; /// - /// Whether a ripple effect is shown when the user clicks the button. + /// Shows a ripple effect when the user clicks the button. /// /// /// Defaults to true. diff --git a/src/MudBlazor/Base/MudBaseInput.cs b/src/MudBlazor/Base/MudBaseInput.cs index ae586f4e7d6..49f2db0ce36 100644 --- a/src/MudBlazor/Base/MudBaseInput.cs +++ b/src/MudBlazor/Base/MudBaseInput.cs @@ -19,7 +19,7 @@ public abstract class MudBaseInput : MudFormComponent { private bool _isDirty; /// - /// Whether validation has been performed during a validation cycle. + /// Prevents validation from occurring more than once during a validation cycle. /// /// /// This field is set to true to prevent validation from occurring more than once during a validation cycle. Each change in the will reset this field to false. @@ -42,7 +42,7 @@ protected MudBaseInput() } /// - /// Whether the component can receive input. + /// Allows the component to receive input. /// /// /// Defaults to false. @@ -55,7 +55,7 @@ protected MudBaseInput() private bool ParentDisabled { get; set; } /// - /// Whether the input can be changed by the user. + /// Prevents the input from being changed by the user. /// /// /// Defaults to false. When true, the user can copy text in the control, but cannot change the . @@ -68,7 +68,7 @@ protected MudBaseInput() private bool ParentReadOnly { get; set; } /// - /// Whether this input fills the full width of its container. + /// Fills the full width of the parent container. /// /// /// Defaults to false. @@ -78,7 +78,7 @@ protected MudBaseInput() public bool FullWidth { get; set; } /// - /// Whether the is changed as soon as input is received. + /// Changes the as soon as input is received. /// /// /// Defaults to false. When true, the property will be updated any time user input occurs. Otherwise, is updated when the user presses Enter or the input loses focus. @@ -88,7 +88,7 @@ protected MudBaseInput() public bool Immediate { get; set; } /// - /// Whether the input has an underline. + /// Displays an underline for the input. /// /// /// Defaults to true. @@ -108,7 +108,7 @@ protected MudBaseInput() public string? HelperText { get; set; } /// - /// Whether the is only shown when this input has focus. + /// Displays the only when this input has focus. /// /// /// Defaults to false. @@ -148,7 +148,7 @@ protected MudBaseInput() public Adornment Adornment { get; set; } = Adornment.None; /// - /// Whether validation only occurs when the user changes the . + /// Limits validation to when the user changes the . /// /// /// Defaults to false. When true, validation only occurs if the user has changed the input value at least once. @@ -261,7 +261,7 @@ protected MudBaseInput() public string? Label { get; set; } /// - /// Whether this input automatically receives focus. + /// Automatically receives focus. /// /// /// Defaults to false. When true, the input will receive focus automatically. @@ -285,7 +285,7 @@ protected MudBaseInput() public string? Text { get; set; } /// - /// Whether the text cannot be updated via a bound value. + /// Prevents the text from being updated via a bound value. /// /// /// Defaults to true. Applies only to Blazor Server (BSS) applications. When false, the input's text can be updated programmatically while the input has focus. @@ -315,7 +315,7 @@ protected MudBaseInput() public virtual string? Pattern { get; set; } /// - /// Whether the label is allowed to appear inside the input if no is specified. + /// Shows the label inside the input if no is specified. /// /// /// Defaults to false. When true, the label will not move into the input when the input is empty. @@ -349,7 +349,7 @@ protected MudBaseInput() public EventCallback OnKeyDown { get; set; } /// - /// Whether the default key-down action occurs. + /// Allows the default key-down action to occur. /// /// /// When true, the browser will not perform its default behavior when a key-down occurs. This is typically used when a key-down needs to override a browser's default behavior. @@ -365,7 +365,7 @@ protected MudBaseInput() public EventCallback OnKeyUp { get; set; } /// - /// Whether the default key-up action occurs. + /// Prevents the default key-up action. /// /// /// When true, the browser will not perform its default behavior when a key-up occurs. This is typically used when a key-up needs to override the browser's default behavior. diff --git a/src/MudBlazor/Base/MudBaseSelectItem.cs b/src/MudBlazor/Base/MudBaseSelectItem.cs index 04e09fff09d..be18b2d74d3 100644 --- a/src/MudBlazor/Base/MudBaseSelectItem.cs +++ b/src/MudBlazor/Base/MudBaseSelectItem.cs @@ -14,15 +14,18 @@ public abstract class MudBaseSelectItem : MudComponentBase private NavigationManager UriHelper { get; set; } = null!; /// - /// Whether the user can interact with this item. + /// Prevents the user from interacting with this item. /// [Parameter] [Category(CategoryTypes.General.Behavior)] public bool Disabled { get; set; } /// - /// Whether to show a ripple effect when the user clicks the button. Default is true. + /// Shows a ripple effect when the user clicks the button. /// + /// + /// Defaults to true. + /// [Parameter] [Category(CategoryTypes.General.Appearance)] public bool Ripple { get; set; } = true; @@ -35,7 +38,7 @@ public abstract class MudBaseSelectItem : MudComponentBase public string? Href { get; set; } /// - /// Whether a full page load occurs during navigation. + /// Performs a full page load during navigation. /// /// /// Defaults to false. When true, client-side routing is bypassed and the browser is forced to load the new page from the server. diff --git a/src/MudBlazor/Base/MudBooleanInput.cs b/src/MudBlazor/Base/MudBooleanInput.cs index a637bd347d4..af5e6bd2101 100644 --- a/src/MudBlazor/Base/MudBooleanInput.cs +++ b/src/MudBlazor/Base/MudBooleanInput.cs @@ -18,7 +18,7 @@ public class MudBooleanInput : MudFormComponent public MudBooleanInput() : base(new BoolConverter()) { } /// - /// Whether the user can interact with this input. + /// Prevents the user from interacting with this input. /// /// /// Defaults to false. @@ -33,7 +33,7 @@ public class MudBooleanInput : MudFormComponent protected bool GetDisabledState() => Disabled || ParentDisabled; /// - /// Whether the use can change the input. + /// Prevents the user from changing the input. /// /// /// Defaults to false. When true, the user can copy the input but cannot change it. @@ -63,7 +63,7 @@ public class MudBooleanInput : MudFormComponent } /// - /// Whether the parent component also handles the click event. + /// Prevents the parent component from receiving click events. /// /// /// Defaults to true. When true, the click will not bubble up to parent components. diff --git a/src/MudBlazor/Base/MudComponentBase.cs b/src/MudBlazor/Base/MudComponentBase.cs index 93838347450..468ede0f77b 100644 --- a/src/MudBlazor/Base/MudComponentBase.cs +++ b/src/MudBlazor/Base/MudComponentBase.cs @@ -66,8 +66,11 @@ public abstract class MudComponentBase : ComponentBaseWithState, IMudStateHasCha public Dictionary UserAttributes { get; set; } = new Dictionary(); /// - /// Whether is available. + /// Whether the is available. /// + /// + /// When true, JavaScript interop calls can be made. + /// protected bool IsJSRuntimeAvailable { get; set; } /// diff --git a/src/MudBlazor/Base/MudFormComponent.cs b/src/MudBlazor/Base/MudFormComponent.cs index d4a8e598192..7caef61c5b7 100644 --- a/src/MudBlazor/Base/MudFormComponent.cs +++ b/src/MudBlazor/Base/MudFormComponent.cs @@ -44,7 +44,7 @@ protected MudFormComponent(Converter converter) internal bool SubscribeToParentForm { get; set; } = true; /// - /// Whether an input is required. + /// Requires an input value. /// /// /// Defaults to false. When true, an error with the text in will be shown during validation if no input was given. @@ -71,7 +71,7 @@ protected MudFormComponent(Converter converter) public string? ErrorText { get; set; } /// - /// Whether an error is displayed. + /// Displays an error. /// /// /// Defaults to false. When true, the text in is displayed. @@ -156,7 +156,7 @@ protected virtual void OnConversionErrorOccurred(string error) } /// - /// Whether a problem has occurred during conversion. + /// Indicates a problem has occurred during conversion. /// /// /// When true, the was unable to convert values, usually due to invalid input. @@ -173,7 +173,7 @@ protected virtual void OnConversionErrorOccurred(string error) public string? ConversionErrorMessage => _converter.GetErrorMessage; /// - /// Whether an error, conversion error, or validation error is active. + /// Indicates any error, conversion error, or validation error with this input. /// /// /// When true, the property is true, or is true, or one or more exists. @@ -203,7 +203,7 @@ protected virtual void OnConversionErrorOccurred(string error) } /// - /// Whether the user has interacted with this input, or focus has been released. + /// Indicates whether the user has interacted with this input or the focus has been released. /// /// /// Defaults to false. When true, the user has performed input, or focus has moved away from this input. This property is typically used to show the text only after the user has interacted with this input. @@ -671,7 +671,7 @@ internal void EditFormValidate() public Expression>? For { get; set; } /// - /// Whether the property is null. + /// Indicates whether the property is null. /// [MemberNotNullWhen(false, nameof(For))] public bool IsForNull => For is null; diff --git a/src/MudBlazor/Components/Alert/MudAlert.razor.cs b/src/MudBlazor/Components/Alert/MudAlert.razor.cs index 98dba31dbc1..195bd55ed22 100644 --- a/src/MudBlazor/Components/Alert/MudAlert.razor.cs +++ b/src/MudBlazor/Components/Alert/MudAlert.razor.cs @@ -45,12 +45,6 @@ private HorizontalAlignment ConvertHorizontalAlignment(HorizontalAlignment conte }; } - /// - /// Gets or sets whether Right-to-Left (RTL) mode is enabled. - /// - /// - /// Defaults to false. When true, text will be displayed right-to-left. - /// [CascadingParameter(Name = "RightToLeft")] public bool RightToLeft { get; set; } diff --git a/src/MudBlazor/Components/AppBar/MudAppBar.razor.cs b/src/MudBlazor/Components/AppBar/MudAppBar.razor.cs index 437a2a9aaef..e7e4420f318 100644 --- a/src/MudBlazor/Components/AppBar/MudAppBar.razor.cs +++ b/src/MudBlazor/Components/AppBar/MudAppBar.razor.cs @@ -28,14 +28,14 @@ public partial class MudAppBar : MudComponentBase .Build(); /// - /// Gets or sets whether the appbar will be placed at the bottom of the screen instead of the top. + /// Places the appbar at the bottom of the screen instead of the top. /// [Parameter] [Category(CategoryTypes.AppBar.Behavior)] public bool Bottom { get; set; } /// - /// Gets or sets the size of the drop shadow. + /// The size of the drop shadow. /// /// /// Defaults to 4. A higher number creates a heavier drop shadow. Use a value of 0 for no shadow. @@ -45,7 +45,7 @@ public partial class MudAppBar : MudComponentBase public int Elevation { set; get; } = 4; /// - /// Gets or sets whether compact padding will be used. + /// Uses compact padding. /// /// /// Defaults to false. @@ -55,7 +55,7 @@ public partial class MudAppBar : MudComponentBase public bool Dense { get; set; } /// - /// Gets or sets whether left and right padding is added to the appbar. + /// Adds left and right padding to this appbar. /// /// /// Defaults to true. @@ -65,27 +65,27 @@ public partial class MudAppBar : MudComponentBase public bool Gutters { get; set; } = true; /// - /// Gets or sets the color of the component. It supports the theme colors. + /// The color of this appbar. /// /// - /// Defaults to . + /// Defaults to . Theme colors are supported. /// [Parameter] [Category(CategoryTypes.AppBar.Appearance)] public Color Color { get; set; } = Color.Default; /// - /// Gets or sets whether the appbar remains in the same place when the page is scrolled. + /// Fixes this appbar in place as the page is scrolled. /// /// - /// Defaults to true. + /// Defaults to true. When false, the appbar will scroll with other page content. /// [Parameter] [Category(CategoryTypes.AppBar.Behavior)] public bool Fixed { get; set; } = true; /// - /// Gets or sets whether the appbar content is allowed to wrap. + /// Allows appbar content to wrap. /// /// /// Defaults to false. @@ -95,7 +95,7 @@ public partial class MudAppBar : MudComponentBase public bool WrapContent { get; set; } = false; /// - /// Gets or sets CSS classes applied to the nested toolbar. + /// The CSS classes applied to the nested toolbar. /// /// /// Defaults to null. You can use spaces to separate multiple classes. @@ -105,7 +105,7 @@ public partial class MudAppBar : MudComponentBase public string? ToolBarClass { get; set; } /// - /// Gets or sets any child content for the component. + /// The content within this component. /// [Parameter] [Category(CategoryTypes.AppBar.Behavior)] diff --git a/src/MudBlazor/Components/Autocomplete/MudAutocomplete.razor.cs b/src/MudBlazor/Components/Autocomplete/MudAutocomplete.razor.cs index 6f21f121d15..7692a45b600 100644 --- a/src/MudBlazor/Components/Autocomplete/MudAutocomplete.razor.cs +++ b/src/MudBlazor/Components/Autocomplete/MudAutocomplete.razor.cs @@ -117,7 +117,7 @@ public partial class MudAutocomplete : MudBaseInput public Origin TransformOrigin { get; set; } = Origin.TopCenter; /// - /// Whether compact padding will be used. + /// Uses compact padding. /// /// /// Defaults to false. @@ -181,7 +181,7 @@ public partial class MudAutocomplete : MudBaseInput } /// - /// Whether to show the progress indicator during searches. + /// Shows the progress indicator during searches. /// /// /// Defaults to false. The progress indicator uses the color specified in the property. @@ -231,7 +231,7 @@ public partial class MudAutocomplete : MudBaseInput public int MinCharacters { get; set; } = 0; /// - /// Whether to reset the selected value if the user deletes the text. + /// Reset the selected value if the user deletes the text. /// /// /// Defaults to false. @@ -241,7 +241,7 @@ public partial class MudAutocomplete : MudBaseInput public bool ResetValueOnEmptyText { get; set; } /// - /// Whether the text will be selected (highlighted) when the component receives focus. + /// Highlights the text when the component receives focus. /// /// /// Defaults to true. @@ -251,7 +251,7 @@ public partial class MudAutocomplete : MudBaseInput public bool SelectOnActivation { get; set; } = true; /// - /// Whether other items can be selected without resetting the Value. + /// Selects items without resetting the Value. /// /// /// Defaults to true. When true, selecting an option will trigger a with the current Text. Otherwise, an empty string is passed which can make it easier to view and select other options without resetting the Value. When false, T must either be a record or override the GetHashCode and Equals methods. @@ -361,7 +361,7 @@ public partial class MudAutocomplete : MudBaseInput public RenderFragment ProgressIndicatorInPopoverTemplate { get; set; } /// - /// Whether the Text property is overridden when an item is selected. + /// Overrides the Text property when an item is selected. /// /// /// Defaults to true. When true, selecting a value will update the Text property. When false, incomplete values for Text are allowed. @@ -371,7 +371,7 @@ public partial class MudAutocomplete : MudBaseInput public bool CoerceText { get; set; } = true; /// - /// Whether the Value property is set even if no match is found by . + /// Sets the Value property even if no match is found by . /// /// /// Defaults to false. When true, the user input will be applied to the Value property which allows it to be validated and show an error message. @@ -397,7 +397,7 @@ public partial class MudAutocomplete : MudBaseInput public EventCallback OpenChanged { get; set; } /// - /// Whether pressing the Tab key updates the Value to the currently selected item. + /// Updates the Value to the currently selected item when pressing the Tab key. /// /// /// Defaults to false. @@ -407,7 +407,7 @@ public partial class MudAutocomplete : MudBaseInput public bool SelectValueOnTab { get; set; } /// - /// Whether a Clear icon button is displayed. + /// Displays the Clear icon button. /// /// /// Defaults to false. When true, an icon is displayed which, when clicked, clears the Text and Value. Use the ClearIcon property to control the Clear button icon. @@ -435,7 +435,7 @@ public partial class MudAutocomplete : MudBaseInput public EventCallback ReturnedItemsCountChanged { get; set; } /// - /// Whether the search result drop-down is currently displayed. + /// Displays the search result drop-down. /// /// /// When this property changes, the event will occur. diff --git a/src/MudBlazor/Components/Avatar/MudAvatar.razor.cs b/src/MudBlazor/Components/Avatar/MudAvatar.razor.cs index ee57325d25b..439b2c8756c 100644 --- a/src/MudBlazor/Components/Avatar/MudAvatar.razor.cs +++ b/src/MudBlazor/Components/Avatar/MudAvatar.razor.cs @@ -40,7 +40,7 @@ partial class MudAvatar : MudComponentBase, IDisposable public int Elevation { set; get; } = 0; /// - /// Whether rounded corners are disabled. + /// Disables rounded corners. /// /// /// Defaults to false. @@ -50,7 +50,7 @@ partial class MudAvatar : MudComponentBase, IDisposable public bool Square { get; set; } /// - /// Whether corners are rounded. + /// Shows rounded corners. /// /// /// Defaults to false. When true, the border-radius style is set to the theme's default value. diff --git a/src/MudBlazor/Components/Avatar/MudAvatarGroup.razor.cs b/src/MudBlazor/Components/Avatar/MudAvatarGroup.razor.cs index afee7dac908..5613eaf6d9f 100644 --- a/src/MudBlazor/Components/Avatar/MudAvatarGroup.razor.cs +++ b/src/MudBlazor/Components/Avatar/MudAvatarGroup.razor.cs @@ -35,7 +35,7 @@ partial class MudAvatarGroup : MudComponentBase public int Spacing { get; set; } = 3; /// - /// Whether an outline is displayed for the group. + /// Displays an outline for the group. /// /// /// Defaults to true. This property is useful to differentiate avatars which are the same color or use images. @@ -62,7 +62,7 @@ partial class MudAvatarGroup : MudComponentBase public int MaxElevation { set; get; } = 0; /// - /// Whether rounded corners are disabled when the number of avatars exceeds . + /// Disables rounded corners when the number of avatars exceeds . /// /// /// Defaults to false. When true, the border-radius CSS style is set to 0. @@ -72,7 +72,7 @@ partial class MudAvatarGroup : MudComponentBase public bool MaxSquare { get; set; } /// - /// Whether corners are rounded when the number of avatars exceeds . + /// Shows rounded corners when the number of avatars exceeds . /// /// /// Defaults to false. When true, the border-radius style is set to the theme's default value. diff --git a/src/MudBlazor/Components/Badge/MudBadge.razor.cs b/src/MudBlazor/Components/Badge/MudBadge.razor.cs index a7e9abb5635..88da50e7592 100644 --- a/src/MudBlazor/Components/Badge/MudBadge.razor.cs +++ b/src/MudBlazor/Components/Badge/MudBadge.razor.cs @@ -52,7 +52,7 @@ public partial class MudBadge : MudComponentBase public int Elevation { set; get; } = 0; /// - /// Whether the badge can be seen. + /// Displays this badge. /// /// /// Defaults to true. @@ -72,7 +72,7 @@ public partial class MudBadge : MudComponentBase public Color Color { get; set; } = Color.Default; /// - /// Whether a dot is displayed instead of any content. + /// Displays a dot instead of any content. /// /// /// Defaults to false. @@ -82,7 +82,7 @@ public partial class MudBadge : MudComponentBase public bool Dot { get; set; } /// - /// Whether to display over the main badge content. + /// Displays over the main badge content. /// /// /// Defaults to false. @@ -92,7 +92,7 @@ public partial class MudBadge : MudComponentBase public bool Overlap { get; set; } /// - /// Whether a border is displayed around the badge. + /// Displays a border around the badge. /// /// /// Defaults to false. diff --git a/src/MudBlazor/Components/Breadcrumbs/BreadcrumbItem.cs b/src/MudBlazor/Components/Breadcrumbs/BreadcrumbItem.cs index 7eeec351996..a801ecfa4ad 100644 --- a/src/MudBlazor/Components/Breadcrumbs/BreadcrumbItem.cs +++ b/src/MudBlazor/Components/Breadcrumbs/BreadcrumbItem.cs @@ -21,7 +21,7 @@ public class BreadcrumbItem public string? Href { get; } /// - /// Whether this item cannot be clicked. + /// Prevents this item from being clicked. /// public bool Disabled { get; } diff --git a/src/MudBlazor/Components/Breadcrumbs/MudBreadcrumbs.razor.cs b/src/MudBlazor/Components/Breadcrumbs/MudBreadcrumbs.razor.cs index 103b1df92d1..c45bdba697e 100644 --- a/src/MudBlazor/Components/Breadcrumbs/MudBreadcrumbs.razor.cs +++ b/src/MudBlazor/Components/Breadcrumbs/MudBreadcrumbs.razor.cs @@ -67,7 +67,7 @@ public partial class MudBreadcrumbs : MudComponentBase public string ExpanderIcon { get; set; } = Icons.Material.Filled.SettingsEthernet; /// - /// Whether items are allowed to be collapsed when the number of items exceeds . + /// Collapses items when the number of items exceeds . /// /// /// Defaults to true. diff --git a/src/MudBlazor/Components/Button/MudButton.razor.cs b/src/MudBlazor/Components/Button/MudButton.razor.cs index c83402a12a8..1dab8aaf0c5 100644 --- a/src/MudBlazor/Components/Button/MudButton.razor.cs +++ b/src/MudBlazor/Components/Button/MudButton.razor.cs @@ -111,7 +111,7 @@ public partial class MudButton : MudBaseButton, IHandleEvent public Variant Variant { get; set; } = Variant.Text; /// - /// Whether the button takes up 100% of the container width. + /// Expands the button to 100% of the container width. /// /// /// Defaults to false. diff --git a/src/MudBlazor/Components/ButtonGroup/MudButtonGroup.razor.cs b/src/MudBlazor/Components/ButtonGroup/MudButtonGroup.razor.cs index fd9116e9460..460ac0f7737 100644 --- a/src/MudBlazor/Components/ButtonGroup/MudButtonGroup.razor.cs +++ b/src/MudBlazor/Components/ButtonGroup/MudButtonGroup.razor.cs @@ -22,17 +22,11 @@ public partial class MudButtonGroup : MudComponentBase .AddClass(Class) .Build(); - /// - /// Whether text is displayed Right-to-Left (RTL). - /// - /// - /// Defaults to false. When true, text will display property for RTL languages such as Arabic, Hebrew, and Persian. - /// [CascadingParameter(Name = "RightToLeft")] public bool RightToLeft { get; set; } /// - /// Whether this group's style overrides the style of individual buttons. + /// Overrides individual button styles with this group's style. /// /// /// Defaults to true. When true, the button styles are defined by this group. @@ -52,7 +46,7 @@ public partial class MudButtonGroup : MudComponentBase public RenderFragment? ChildContent { get; set; } /// - /// Whether buttons are displayed vertically. + /// Displays buttons vertically. /// /// /// Defaults to false. When true, buttons will be displayed vertically, otherwise horizontally. @@ -62,7 +56,7 @@ public partial class MudButtonGroup : MudComponentBase public bool Vertical { get; set; } /// - /// Whether a shadow is displayed. + /// Displays a shadow. /// /// /// Defaults to true. diff --git a/src/MudBlazor/Components/Card/MudCard.razor.cs b/src/MudBlazor/Components/Card/MudCard.razor.cs index 9e67929dbba..106a2cccb3f 100644 --- a/src/MudBlazor/Components/Card/MudCard.razor.cs +++ b/src/MudBlazor/Components/Card/MudCard.razor.cs @@ -24,7 +24,7 @@ public partial class MudCard : MudComponentBase public int Elevation { set; get; } = 1; /// - /// Whether rounded corners are disabled. + /// Disables rounded corners. /// /// /// Defaults to false. @@ -34,7 +34,7 @@ public partial class MudCard : MudComponentBase public bool Square { get; set; } /// - /// Whether an outline is displayed. + /// Displays an outline. /// /// /// Defaults to false. This property is useful to differentiate cards which are the same color or use images. diff --git a/src/MudBlazor/Components/Carousel/MudCarousel.razor.cs b/src/MudBlazor/Components/Carousel/MudCarousel.razor.cs index f7e0e361a76..f10f1d602df 100644 --- a/src/MudBlazor/Components/Carousel/MudCarousel.razor.cs +++ b/src/MudBlazor/Components/Carousel/MudCarousel.razor.cs @@ -33,17 +33,11 @@ public partial class MudCarousel : MudBaseBindableItemsControl - /// Whether text is displayed Right-to-Left (RTL). - /// - /// - /// Defaults to false. When true, text will display property for RTL languages such as Arabic, Hebrew, and Persian. - /// [CascadingParameter(Name = "RightToLeft")] public bool RightToLeft { get; set; } /// - /// Whether "Next" and "Previous" arrows are displayed. + /// Displays "Next" and "Previous" arrows. /// /// /// Defaults to true. @@ -63,7 +57,7 @@ public partial class MudCarousel : MudBaseBindableItemsControl - /// Whether a bullet is displayed for each . + /// Displays a bullet for each . /// /// /// Defaults to true. @@ -93,7 +87,7 @@ public partial class MudCarousel : MudBaseBindableItemsControl - /// Whether items are automatically cycled. + /// Automatically cycles items based on . /// /// /// Defaults to false. When true, the items will be rotated after the delay specified in . @@ -223,7 +217,7 @@ public TimeSpan AutoCycleTime public RenderFragment? BulletTemplate { get; set; } /// - /// Whether swipe gestures are allowed for touch devices. + /// Allows swipe gestures for touch devices. /// /// /// Defaults to true. When true, swipe gestures on touch devices can be used to change the current . diff --git a/src/MudBlazor/Components/Carousel/MudCarouselItem.razor.cs b/src/MudBlazor/Components/Carousel/MudCarouselItem.razor.cs index 62d3d3c0106..25710fc1ed4 100644 --- a/src/MudBlazor/Components/Carousel/MudCarouselItem.razor.cs +++ b/src/MudBlazor/Components/Carousel/MudCarouselItem.razor.cs @@ -42,12 +42,6 @@ public partial class MudCarouselItem : MudComponentBase, IDisposable [CascadingParameter] protected internal MudBaseItemsControl? Parent { get; set; } - /// - /// Whether text is displayed Right-to-Left (RTL). - /// - /// - /// Defaults to false. When true, text will display property for RTL languages such as Arabic, Hebrew, and Persian. - /// [CascadingParameter(Name = "RightToLeft")] public bool RightToLeft { get; set; } @@ -86,7 +80,7 @@ public partial class MudCarouselItem : MudComponentBase, IDisposable public string? CustomTransitionExit { get; set; } /// - /// Whether this item is currently visible. + /// Displays this item. /// public bool Visible => Parent is not null && (Parent.LastContainer == this || Parent.SelectedIndex == Parent.Items.IndexOf(this)); diff --git a/src/MudBlazor/Components/Chart/Models/ChartOptions.cs b/src/MudBlazor/Components/Chart/Models/ChartOptions.cs index 46ea13720dc..699d56c136d 100644 --- a/src/MudBlazor/Components/Chart/Models/ChartOptions.cs +++ b/src/MudBlazor/Components/Chart/Models/ChartOptions.cs @@ -35,7 +35,7 @@ public class ChartOptions public string YAxisFormat { get; set; } /// - /// Whether vertical axis lines are shown. + /// Shows vertical axis lines. /// /// /// Defaults to true. @@ -43,7 +43,7 @@ public class ChartOptions public bool YAxisLines { get; set; } = true; /// - /// Whether horizontal axis lines are shown. + /// Shows horizontal axis lines. /// /// /// Defaults to false. @@ -51,7 +51,7 @@ public class ChartOptions public bool XAxisLines { get; set; } /// - /// Whether the legend is shown. + /// Shows the chart series legend. /// /// /// Defaults to true. diff --git a/src/MudBlazor/Components/Chart/Models/ChartSeries.cs b/src/MudBlazor/Components/Chart/Models/ChartSeries.cs index 6a6f812a264..797e1fc0e47 100644 --- a/src/MudBlazor/Components/Chart/Models/ChartSeries.cs +++ b/src/MudBlazor/Components/Chart/Models/ChartSeries.cs @@ -25,7 +25,7 @@ public class ChartSeries public double[] Data { get; set; } /// - /// Whether this series is displayed in the chart. + /// Displays this series in the chart. /// public bool Visible { get; set; } = true; diff --git a/src/MudBlazor/Components/Chart/MudChart.razor.cs b/src/MudBlazor/Components/Chart/MudChart.razor.cs index 25aeaa888fd..ee687fcfc6d 100644 --- a/src/MudBlazor/Components/Chart/MudChart.razor.cs +++ b/src/MudBlazor/Components/Chart/MudChart.razor.cs @@ -75,12 +75,6 @@ public abstract class MudChartBase : MudComponentBase .AddClass(Class) .Build(); - /// - /// Whether text is displayed Right-to-Left (RTL). - /// - /// - /// Defaults to false. When true, text will display property for RTL languages such as Arabic, Hebrew, and Persian. - /// [CascadingParameter(Name = "RightToLeft")] public bool RightToLeft { get; set; } @@ -180,7 +174,7 @@ protected string ToS(double d, string format = null) } /// - /// Whether lines can be hidden when is . + /// Allows series to be hidden when is . /// /// /// When true, checkboxes are displayed which can toggle visibility of each line. diff --git a/src/MudBlazor/Components/CheckBox/MudCheckBox.razor.cs b/src/MudBlazor/Components/CheckBox/MudCheckBox.razor.cs index bbde9e3b2e7..224fdbff8c1 100644 --- a/src/MudBlazor/Components/CheckBox/MudCheckBox.razor.cs +++ b/src/MudBlazor/Components/CheckBox/MudCheckBox.razor.cs @@ -83,7 +83,7 @@ public partial class MudCheckBox : MudBooleanInput public LabelPosition LabelPosition { get; set; } = LabelPosition.End; /// - /// Whether the checkbox can be controlled with the keyboard. + /// Allows this checkbox to be controlled via the keyboard. /// /// /// Defaults to true. The Space key cycles through true and false values (or true/false/null states if is true). Delete will clear the checkbox. Enter (or NumPadEnter) will set the checkbox. Backspace will set an indeterminate value. @@ -93,7 +93,7 @@ public partial class MudCheckBox : MudBooleanInput public bool KeyboardEnabled { get; set; } = true; /// - /// Whether a ripple effect is shown whhen the checkbox is clicked. + /// Shows a ripple effect when this checkbox is clicked. /// /// /// Defaults to true. @@ -103,7 +103,7 @@ public partial class MudCheckBox : MudBooleanInput public bool Ripple { get; set; } = true; /// - /// Whether compact padding will be used. + /// Uses compact padding. /// /// /// Defaults to false. @@ -160,7 +160,7 @@ public partial class MudCheckBox : MudBooleanInput public string IndeterminateIcon { get; set; } = Icons.Material.Filled.IndeterminateCheckBox; /// - /// Whether the checkbox can cycle to an indeterminate state. + /// Allows the checkbox to have an indeterminate state. /// /// /// Defaults to false. When true, the checkbox can support an indeterminate state such as a null value, in addition to true and false. diff --git a/src/MudBlazor/Components/Chip/MudChip.razor.cs b/src/MudBlazor/Components/Chip/MudChip.razor.cs index e823a87c193..41575d72e78 100644 --- a/src/MudBlazor/Components/Chip/MudChip.razor.cs +++ b/src/MudBlazor/Components/Chip/MudChip.razor.cs @@ -155,7 +155,7 @@ private Color GetColor() public RenderFragment? AvatarContent { get; set; } /// - /// Whether the theme border radius is used for the chip edges. + /// Uses the theme border radius for chip edges. /// /// /// Defaults to null. When true, the is used for chip edges. @@ -165,7 +165,7 @@ private Color GetColor() public bool? Label { get; set; } /// - /// Whether the user cannot interact with this chip. + /// Prevents the user from interacting with this chip. /// /// /// Defaults to false. When true, the chip is visibly disabled and interaction is not allowed. @@ -212,7 +212,7 @@ private Color GetColor() public string? CloseIcon { get; set; } /// - /// Whether a ripple effect is show when the chip is clicked. + /// Displays a ripple effect when this chip is clicked. /// /// /// Defaults to null. @@ -269,7 +269,7 @@ private Color GetColor() public T? Value { get; set; } /// - /// Whether a full page refresh is performed when navigating to the URL in . + /// Performs a full page refresh when navigating to the URL in . /// /// /// Defaults to false. When true, client-side routing is bypassed and a full page reload occurs. @@ -279,7 +279,7 @@ private Color GetColor() public bool ForceLoad { get; set; } /// - /// Whether this chip is selected by default when part of a . + /// Selects this chip by default when part of a . /// /// /// Defaults to null. @@ -306,7 +306,7 @@ private Color GetColor() internal bool ShowCheckMark => SelectedState.Value && ChipSet?.CheckMark == true; /// - /// Whether this chip is selected. + /// Selects this chip. /// /// /// When true, the chip is displayed in a selected state. diff --git a/src/MudBlazor/Components/ChipSet/MudChipSet.razor.cs b/src/MudBlazor/Components/ChipSet/MudChipSet.razor.cs index 2e25a069bf3..ea745d7a567 100644 --- a/src/MudBlazor/Components/ChipSet/MudChipSet.razor.cs +++ b/src/MudBlazor/Components/ChipSet/MudChipSet.razor.cs @@ -68,7 +68,7 @@ public MudChipSet() public SelectionMode SelectionMode { get; set; } = SelectionMode.SingleSelection; /// - /// Whether all chips in this set are closeable. + /// Allows all chips in this set to be closed. /// /// /// Defaults to false. @@ -128,7 +128,7 @@ public MudChipSet() public Size Size { get; set; } = Size.Medium; /// - /// Whether checkmarks are shown for selected chips. + /// Shows checkmarks for selected chips. /// [Parameter] [Category(CategoryTypes.ChipSet.Appearance)] @@ -155,7 +155,7 @@ public MudChipSet() public string CloseIcon { get; set; } = Icons.Material.Filled.Cancel; /// - /// Whether a ripple effect is shown for chips in this set. + /// Shows a ripple effect when a chip is clicked. /// /// /// Defaults to true. Can be overridden by setting . @@ -165,7 +165,7 @@ public MudChipSet() public bool Ripple { get; set; } = true; /// - /// Whether the theme border radius is used be default for chips in this set. + /// Uses the theme border radius for chips in this set. /// /// /// Defaults to false. When true, the is used for chip edges. Can be overridden by setting . @@ -175,7 +175,7 @@ public MudChipSet() public bool Label { get; set; } /// - /// Whether the user cannot interact with this chip. + /// Prevents the user from interacting with chips in this set. /// /// /// Defaults to false. When true, the all chips are visibly disabled and interaction is not allowed. Overrides any value set for . @@ -185,7 +185,7 @@ public MudChipSet() public bool Disabled { get; set; } /// - /// Whether chips in this set are clickable. + /// Prevents chips in this set from being clicked. /// /// /// Defaults to false. When true, chips cannot be clicked even if is set. diff --git a/src/MudBlazor/Components/Collapse/MudCollapse.razor.cs b/src/MudBlazor/Components/Collapse/MudCollapse.razor.cs index 484516fc185..c5d22bd6684 100644 --- a/src/MudBlazor/Components/Collapse/MudCollapse.razor.cs +++ b/src/MudBlazor/Components/Collapse/MudCollapse.razor.cs @@ -42,7 +42,7 @@ internal enum CollapseState .Build(); /// - /// Whether content within this panel is visible. + /// Displays content within this panel. /// /// /// Defaults to false. diff --git a/src/MudBlazor/Components/ColorPicker/MudColorPicker.razor.cs b/src/MudBlazor/Components/ColorPicker/MudColorPicker.razor.cs index 23b6acd5bea..c70350ce988 100644 --- a/src/MudBlazor/Components/ColorPicker/MudColorPicker.razor.cs +++ b/src/MudBlazor/Components/ColorPicker/MudColorPicker.razor.cs @@ -15,6 +15,9 @@ namespace MudBlazor { + /// + /// Represents a sophisticated and customizable pop-up for choosing a color. + /// public partial class MudColorPicker : MudPicker { private readonly ParameterState _throttleIntervalState; @@ -64,13 +67,17 @@ public MudColorPicker() : base(new DefaultConverter()) #region Parameters - [CascadingParameter(Name = "RightToLeft")] public bool RightToLeft { get; set; } + [CascadingParameter(Name = "RightToLeft")] + public bool RightToLeft { get; set; } private bool _alpha = true; /// - /// If true, Alpha options will be displayed and color output will be RGBA, HSLA or HEXA and not RGB, HSL or HEX. + /// Shows alpha transparency options. /// + /// + /// Defaults to true. When true, alpha options will be displayed and color output will be RGBA, HSLA or HEXA instead of RGB, HSL or HEX. + /// [Parameter] [Category(CategoryTypes.FormComponent.PickerBehavior)] public bool ShowAlpha @@ -93,43 +100,61 @@ public bool ShowAlpha } /// - /// If true, the color field will be displayed. + /// Displays the color field. /// + /// + /// Defaults to true. + /// [Parameter] [Category(CategoryTypes.FormComponent.PickerBehavior)] public bool ShowColorField { get; set; } = true; /// - /// If true, the switch to change color mode will be displayed. + /// Displays the switch to change the color mode. /// + /// + /// Defaults to true. + /// [Parameter] [Category(CategoryTypes.FormComponent.PickerBehavior)] public bool ShowModeSwitch { get; set; } = true; /// - /// If true, textfield inputs and color mode switch will be displayed. + /// Displays the text inputs, current mode, and mode switch. /// + /// + /// Defaults to true. + /// [Parameter] [Category(CategoryTypes.FormComponent.PickerBehavior)] public bool ShowInputs { get; set; } = true; /// - /// If true, hue and alpha sliders will be displayed. + /// Displays hue and alpha sliders. /// + /// + /// Defaults to true. + /// [Parameter] [Category(CategoryTypes.FormComponent.PickerBehavior)] public bool ShowSliders { get; set; } = true; /// - /// If true, the preview color box will be displayed, note that the preview color functions as a button as well for collection colors. + /// Displays a preview of the color. /// + /// + /// Defaults to true. When true, the preview color can be used as a button for collection colors. + /// [Parameter] [Category(CategoryTypes.FormComponent.PickerBehavior)] public bool ShowPreview { get; set; } = true; /// - /// The initial mode (RGB, HSL or HEX) the picker should open. Defaults to RGB + /// The initial color channels shown. /// + /// + /// Defaults to . Other values are for hexadecimal values and for hue/saturation/lightness mode. + /// [Parameter] [Category(CategoryTypes.FormComponent.PickerBehavior)] public ColorPickerMode ColorPickerMode { get; set; } = ColorPickerMode.RGB; @@ -138,8 +163,11 @@ public bool ShowAlpha private ColorPickerView _activeColorPickerView = ColorPickerView.Spectrum; /// - /// The initial view of the picker. Views can be changed if toolbar is enabled. + /// The initial view. /// + /// + /// Defaults to . The view can be changed if ShowToolbar is true. + /// [Parameter] [Category(CategoryTypes.FormComponent.PickerBehavior)] public ColorPickerView ColorPickerView @@ -156,15 +184,21 @@ public ColorPickerView ColorPickerView } /// - /// If true, binding changes occurred also when HSL values changed without a corresponding RGB change + /// Limits updates to the bound value to when HSL values change. /// + /// + /// Defaults to false. When true, the bound value changes when HSL values change, even if the RGB values have not changed. + /// [Parameter] [Category(CategoryTypes.FormComponent.Behavior)] public bool UpdateBindingIfOnlyHSLChanged { get; set; } = false; /// - /// A two-way bindable property representing the selected value. MudColor is a utility class that can be used to get the value as RGB, HSL, hex or other value + /// The currently selected color as a . /// + /// + /// You can use properties in to get color channel values such as RGB, HSL, HEX and more. When this value changes, the event occurs. + /// [Parameter] [Category(CategoryTypes.FormComponent.Data)] public MudColor Value @@ -173,11 +207,18 @@ public MudColor Value set => SetColorAsync(value).AndForget(); } - [Parameter] public EventCallback ValueChanged { get; set; } + /// + /// Occurs when the property has changed. + /// + [Parameter] + public EventCallback ValueChanged { get; set; } /// - /// MudColor list of predefined colors. The first five colors will show up as the quick colors on preview dot click. + /// The list of quick colors to display. /// + /// + /// Defaults to a list of 35 colors. The first five colors show as the quick colors when the preview dot is clicked. + /// [Parameter] [Category(CategoryTypes.FormComponent.PickerBehavior)] public IEnumerable Palette { get; set; } = new MudColor[] @@ -205,62 +246,78 @@ public MudColor Value }; /// - /// - /// When set to false, no mouse move events in the spectrum mode will be captured, so the selector circle won't fellow the mouse. - /// Under some conditions like long latency the visual representation might not reflect the user behaviour anymore. So, it can be disabled. - /// - /// Enabled by default + /// Continues to update the selected color while the mouse button is down. /// + /// + /// Defaults to true. When false, conditions like long latency are better supported and can be adjusted via the property. + /// [Parameter] [Category(CategoryTypes.FormComponent.PickerBehavior)] public bool DragEffect { get; set; } = true; /// - /// Custom close icon. + /// The custom icon to dislay for the close button. /// + /// + /// Defaults to . + /// [Parameter] [Category(CategoryTypes.FormComponent.PickerAppearance)] public string CloseIcon { get; set; } = Icons.Material.Filled.Close; /// - /// Custom spectrum icon. + /// The icon to display for the spectrum mode button. /// + /// + /// Defaults to . + /// [Parameter] [Category(CategoryTypes.FormComponent.PickerAppearance)] public string SpectrumIcon { get; set; } = Icons.Material.Filled.Tune; /// - /// Custom grid icon. + /// The icon to display for the grid mode button. /// + /// + /// Defaults to . + /// [Parameter] [Category(CategoryTypes.FormComponent.PickerAppearance)] public string GridIcon { get; set; } = Icons.Material.Filled.Apps; /// - /// Custom palette icon. + /// The icon to display for the custom palette button. /// + /// + /// Defaults to . + /// [Parameter] [Category(CategoryTypes.FormComponent.PickerAppearance)] public string PaletteIcon { get; set; } = Icons.Material.Filled.Palette; /// - /// Custom import/export icon. + /// The icon to display for the import/export button. /// + /// + /// Defaults to . + /// [Parameter] [Category(CategoryTypes.FormComponent.PickerAppearance)] public string ImportExportIcon { get; set; } = Icons.Material.Filled.ImportExport; /// - /// The delay (in milliseconds) after dragging the pointer before the color binding updates. - /// Updates are instant if the throttling interval is 0. - /// Default interval is 300ms. + /// The delay, in milliseconds, between updates to the selected color when is true. /// + /// + /// Defaults to 300 milliseconds between updates. + /// [Parameter] [Category(CategoryTypes.FormComponent.PickerBehavior)] public int ThrottleInterval { get; set; } = 300; #endregion + /// protected override void OnInitialized() { base.OnInitialized(); @@ -296,6 +353,9 @@ private async Task SelectPaletteColorAsync(MudColor color) } } + /// + /// Refreshes the current color change mode. + /// public void ChangeMode() => ColorPickerMode = ColorPickerMode switch { @@ -305,6 +365,12 @@ private async Task SelectPaletteColorAsync(MudColor color) _ => ColorPickerMode.RGB, }; + /// + /// Changes to the specified color selection view. + /// + /// + /// The new view to display. + /// public void ChangeView(ColorPickerView value) { _activeColorPickerView = value; @@ -467,57 +533,92 @@ private void SetSelectorBasedOnPointerEvents(PointerEventArgs e, bool offsetIsAb #region updating inputs /// - /// Set the R (red) component of the color picker + /// Sets the red channel of the selected color. /// - /// A value between 0 (no red) or 255 (max red) + /// + /// A value between 0 (no red) and 255 (max red). + /// + /// + /// Often used with and . + /// public void SetR(int value) => Value = Value.SetR(value); /// - /// Set the G (green) component of the color picker + /// Sets the green channel of the selected color. /// - /// A value between 0 (no green) or 255 (max green) + /// + /// A value between 0 (no green) and 255 (max green). + /// + /// + /// Often used with and . + /// public void SetG(int value) => Value = Value.SetG(value); /// - /// Set the B (blue) component of the color picker + /// Sets the blue channel of the selected color. /// - /// A value between 0 (no blue) or 255 (max blue) + /// + /// A value between 0 (no blue) and 255 (max blue). + /// + /// + /// Often used with and . + /// public void SetB(int value) => Value = Value.SetB(value); /// - /// Set the H (hue) component of the color picker + /// Sets the hue channel of the selected color. /// - /// A value between 0 and 360 (degrees) + /// + /// A value between 0.0 and 360.0, in degrees. + /// + /// + /// Often used with and . + /// public void SetH(double value) => Value = Value.SetH(value); /// - /// Set the S (saturation) component of the color picker + /// Sets the saturation channel of the selected color. /// - /// A value between 0.0 (no saturation) and 1.0 (max saturation) + /// + /// A value between 0.0 (no saturation) and 1.0 (max saturation). + /// + /// + /// Often used with and . + /// public void SetS(double value) => Value = Value.SetS(value); /// - /// Set the L (Lightness) component of the color picker + /// Sets the lightness channel of the selected color. /// - /// A value between 0.0 (no light, black) and 1.0 (max light, white) + /// + /// A value between 0.0 (darkest/black) and 1.0 (brightest/white). + /// + /// + /// Often used with and . + /// public void SetL(double value) => Value = Value.SetL(value); /// - /// Set the Alpha (transparency) component of the color picker + /// Sets the transparency channel of the selected color. /// - /// A value between 0.0 (full transparent) and 1.0 (solid) + /// + /// A value between 0.0 (fully transparent) and 1.0 (solid). + /// public void SetAlpha(double value) => Value = Value.SetAlpha(value); /// - /// Set the Alpha (transparency) component of the color picker + /// Sets the transparency channel of the selected color. /// - /// A value between 0 (full transparent) and 1 (solid) + /// + /// A value between 0 (fully transparent) and 1 (solid). public void SetAlpha(int value) => Value = Value.SetAlpha(value); /// - /// Set the color of the picker based on the string input + /// Sets the selected color to the specified value. /// - /// Accepting different formats for a color representation such as rbg, rgba, # + /// + /// A string value formatted as hexadecimal (#FF0000), RGB (rgb(255,0,0)), or RGBA (rgba(255,0,0,255). + /// public void SetInputString(string input) { MudColor color; diff --git a/src/MudBlazor/Components/RTLProvider/MudRTLProvider.razor.cs b/src/MudBlazor/Components/RTLProvider/MudRTLProvider.razor.cs index c1b12c44c25..28126ec11fb 100644 --- a/src/MudBlazor/Components/RTLProvider/MudRTLProvider.razor.cs +++ b/src/MudBlazor/Components/RTLProvider/MudRTLProvider.razor.cs @@ -9,6 +9,9 @@ namespace MudBlazor { #nullable enable + /// + /// Represents a language support provider for Right-to-Left (RTL) languages such as Arabic, Hebrew, and Persian. + /// public partial class MudRTLProvider : MudComponentBase { private readonly ParameterState _rtlState; @@ -28,14 +31,17 @@ public MudRTLProvider() .Build(); /// - /// If true, changes the layout to RightToLeft. + /// Displays text Right-to-Left (RTL). /// + /// + /// Defaults to false. When true, text will display properly for RTL languages such as Arabic, Hebrew, and Persian. + /// [Parameter] [Category(CategoryTypes.RTLProvider.Behavior)] public bool RightToLeft { get; set; } /// - /// Child content of the component. + /// The content within this component. /// [Parameter] [Category(CategoryTypes.RTLProvider.Behavior)] diff --git a/src/MudBlazor/Enums/ColorPickerMode.cs b/src/MudBlazor/Enums/ColorPickerMode.cs index e12cd5ed93f..c610bfc47c1 100644 --- a/src/MudBlazor/Enums/ColorPickerMode.cs +++ b/src/MudBlazor/Enums/ColorPickerMode.cs @@ -2,12 +2,25 @@ // MudBlazor licenses this file to you under the MIT license. // See the LICENSE file in the project root for more information. -namespace MudBlazor +namespace MudBlazor; + +/// +/// Indicates the initial mode used by a . +/// +public enum ColorPickerMode { - public enum ColorPickerMode - { - RGB, - HSL, - HEX - } + /// + /// Red, Green, and Blue color values are used. + /// + RGB, + + /// + /// Hue, Saturation, and Lightness color values are used. + /// + HSL, + + /// + /// Hexadecimal values are used. + /// + HEX } diff --git a/src/MudBlazor/Enums/ColorPickerView.cs b/src/MudBlazor/Enums/ColorPickerView.cs index 9627ab37271..e6d1e28e3e2 100644 --- a/src/MudBlazor/Enums/ColorPickerView.cs +++ b/src/MudBlazor/Enums/ColorPickerView.cs @@ -2,13 +2,30 @@ // MudBlazor licenses this file to you under the MIT license. // See the LICENSE file in the project root for more information. -namespace MudBlazor +namespace MudBlazor; + +/// +/// Indicates the color selection view for a . +/// +public enum ColorPickerView { - public enum ColorPickerView - { - Spectrum, - Palette, - Grid, - GridCompact - } + /// + /// Colors are chosen from a gradient of colors. + /// + Spectrum, + + /// + /// Colors are chosen from a pre-defined palette. + /// + Palette, + + /// + /// Colors are chosen from a grid of possible values. + /// + Grid, + + /// + /// Colors are chosen from a smaller grid of possible values. + /// + GridCompact } diff --git a/src/MudBlazor/Services/MudGlobal.cs b/src/MudBlazor/Services/MudGlobal.cs index 1ef7194df31..61f4d469ca7 100644 --- a/src/MudBlazor/Services/MudGlobal.cs +++ b/src/MudBlazor/Services/MudGlobal.cs @@ -19,11 +19,10 @@ public static class DialogDefaults public static class InputDefaults { /// - /// Whether the label is allowed to appear inside the input if no is specified. + /// Shows the label inside the input if no is specified. /// /// - /// Defaults to false. - /// When true, the label will not move into the input when the input is empty. + /// Defaults to false. When true, the label will not move into the input when the input is empty. /// public static bool ShrinkLabel { get; set; } } diff --git a/src/MudBlazor/Utilities/MudColor.cs b/src/MudBlazor/Utilities/MudColor.cs index 7494405f30d..490b72882f4 100644 --- a/src/MudBlazor/Utilities/MudColor.cs +++ b/src/MudBlazor/Utilities/MudColor.cs @@ -87,7 +87,7 @@ public class MudColor : ISerializable, IEquatable public double H { get; } /// - /// Gets the luminance component value of the color. + /// Gets the lightness component value of the color. /// [JsonIgnore] public double L { get; } @@ -121,11 +121,11 @@ public MudColor() } /// - /// Initializes a new instance of the class with the specified hue, saturation, luminance, and alpha values. + /// Initializes a new instance of the class with the specified hue, saturation, lightness, and alpha values. /// /// The hue component value (0 to 360). /// The saturation component value (0.0 to 1.0). - /// The luminance component value (0.0 to 1.0). + /// The lightness component value (0.0 to 1.0). /// The alpha component value (0 to 1.0). public MudColor(double h, double s, double l, double a) : this(h, s, l, (int)(a * 255.0).EnsureRange(255)) @@ -133,11 +133,11 @@ public MudColor(double h, double s, double l, double a) } /// - /// Initializes a new instance of the class with the specified hue, saturation, luminance, and alpha values. + /// Initializes a new instance of the class with the specified hue, saturation, lightness, and alpha values. /// /// The hue component value (0 to 360). /// The saturation component value (0.0 to 1.0). - /// The luminance component value (0.0 to 1.0). + /// The lightness component value (0.0 to 1.0). /// The alpha component value (0 to 255). public MudColor(double h, double s, double l, int a) { @@ -347,24 +347,24 @@ public MudColor(string value) } /// - /// Creates a new instance with the specified hue value while keeping the saturation, luminance, and alpha values unchanged. + /// Creates a new instance with the specified hue value while keeping the saturation, lightness, and alpha values unchanged. /// /// The hue component value (0 to 360). /// A new instance with the specified hue value. public MudColor SetH(double h) => new(h, S, L, A); /// - /// Creates a new instance with the specified saturation value while keeping the hue, luminance, and alpha values unchanged. + /// Creates a new instance with the specified saturation value while keeping the hue, lightness, and alpha values unchanged. /// /// The saturation component value (0.0 to 1.0). /// A new instance with the specified saturation value. public MudColor SetS(double s) => new(H, s, L, A); /// - /// Creates a new instance with the specified luminance value while keeping the hue, saturation, and alpha values unchanged. + /// Creates a new instance with the specified lightness value while keeping the hue, saturation, and alpha values unchanged. /// - /// The luminance component value (0.0 to 1.0). - /// A new instance with the specified luminance value. + /// The lightness component value (0.0 to 1.0). + /// A new instance with the specified lightness value. public MudColor SetL(double l) => new(H, S, l, A); /// @@ -403,10 +403,10 @@ public MudColor(string value) public MudColor SetAlpha(double a) => new(R, G, B, a); /// - /// Creates a new instance by adjusting the luminance component value by the specified amount. + /// Creates a new instance by adjusting the lightness component value by the specified amount. /// - /// The amount to adjust the luminance by (-1.0 to 1.0). - /// A new instance with the adjusted luminance. + /// The amount to adjust the lightness by (-1.0 to 1.0). + /// A new instance with the adjusted lightness. public MudColor ChangeLightness(double amount) => new(H, S, Math.Max(0, Math.Min(1, L + amount)), A); /// @@ -436,7 +436,7 @@ public MudColor(string value) public MudColor ColorRgbDarken() => ColorDarken(0.075); /// - /// Checks whether the HSL (Hue, Saturation, Luminance) values of this instance have changed compared to another instance. + /// Checks whether the HSL (Hue, Saturation, lightness) values of this instance have changed compared to another instance. /// /// The instance to compare HSL values with. /// True if the HSL values have changed; otherwise, false. @@ -589,7 +589,7 @@ private static string[] SplitInputIntoParts(string value) h = ((60D * (r - g)) / (max - min)) + 240D; } - // luminance + // lightness var l = (max + min) / 2D; // saturation