Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

moved picklist icons to be properties. #1947

Merged
merged 1 commit into from
Feb 5, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions Radzen.Blazor/RadzenPickList.razor
Original file line number Diff line number Diff line change
Expand Up @@ -19,13 +19,13 @@
/>
</RadzenStack>
<RadzenStack Orientation="@(Orientation == Orientation.Vertical ? Orientation.Horizontal : Orientation.Vertical)" JustifyContent="@ButtonJustifyContent" Gap="@ButtonGap" class="rz-picklist-buttons">
<RadzenButton Icon="keyboard_arrow_right" title="@SelectedSourceToTargetTitle" Click="@SelectedSourceToTarget" Disabled=@(Disabled || selectedSourceItems == null || (Multiple && (selectedSourceItems as IEnumerable)?.Cast<object>().Any() != true))
<RadzenButton Icon="@SelectedSourceToTargetIcon" title="@SelectedSourceToTargetTitle" Click="@SelectedSourceToTarget" Disabled=@(Disabled || selectedSourceItems == null || (Multiple && (selectedSourceItems as IEnumerable)?.Cast<object>().Any() != true))
ButtonStyle="@ButtonStyle" Size="@ButtonSize" Variant="@ButtonVariant" Shade="@ButtonShade" />
<RadzenButton Icon="keyboard_arrow_left" title="@SelectedTargetToSourceTitle" Click="@SelectedTargetToSource" Disabled=@(Disabled || selectedTargetItems == null || (Multiple && (selectedTargetItems as IEnumerable)?.Cast<object>().Any() != true))
<RadzenButton Icon="@SelectedTargetToSourceIcon" title="@SelectedTargetToSourceTitle" Click="@SelectedTargetToSource" Disabled=@(Disabled || selectedTargetItems == null || (Multiple && (selectedTargetItems as IEnumerable)?.Cast<object>().Any() != true))
ButtonStyle="@ButtonStyle" Size="@ButtonSize" Variant="@ButtonVariant" Shade="@ButtonShade"/>
<RadzenButton Icon="keyboard_double_arrow_right" title="@SourceToTargetTitle" Click="@SourceToTarget" Disabled=@(Disabled || source == null || (source != null && !source.Any()))
<RadzenButton Icon="@SourceToTargetIcon" title="@SourceToTargetTitle" Click="@SourceToTarget" Disabled=@(Disabled || source == null || (source != null && !source.Any()))
ButtonStyle="@ButtonStyle" Size="@ButtonSize" Variant="@ButtonVariant" Shade="@ButtonShade" Visible=@(AllowMoveAll && AllowMoveAllSourceToTarget) />
<RadzenButton Icon="keyboard_double_arrow_left" title="@TargetToSourceTitle" Click="@TargetToSource" Disabled=@(Disabled || target == null|| (target != null && !target.Any()))
<RadzenButton Icon="@TargetToSourceIcon" title="@TargetToSourceTitle" Click="@TargetToSource" Disabled=@(Disabled || target == null|| (target != null && !target.Any()))
ButtonStyle="@ButtonStyle" Size="@ButtonSize" Variant="@ButtonVariant" Shade="@ButtonShade" Visible=@(AllowMoveAll && AllowMoveAllTargetToSource)/>
</RadzenStack>
<RadzenStack class="rz-picklist-target-wrapper">
Expand Down
28 changes: 28 additions & 0 deletions Radzen.Blazor/RadzenPickList.razor.cs
Original file line number Diff line number Diff line change
Expand Up @@ -238,6 +238,34 @@ void OnTargetItemRender(ListBoxItemRenderEventArgs<object> args)
[Parameter]
public string SelectedTargetToSourceTitle { get; set; } = "Move selected target items to source collection";

/// <summary>
/// Gets or sets the source to target icon
/// </summary>
/// <value>The source to target icon.</value>
[Parameter]
public string SourceToTargetIcon { get; set; } = "keyboard_double_arrow_right";

/// <summary>
/// Gets or sets the selected source to target icon
/// </summary>
/// <value>The selected source to target icon.</value>
[Parameter]
public string SelectedSourceToTargetIcon { get; set; } = "keyboard_arrow_right";

/// <summary>
/// Gets or sets the target to source icon
/// </summary>
/// <value>The target to source icon.</value>
[Parameter]
public string TargetToSourceIcon { get; set; } = "keyboard_double_arrow_left";

/// <summary>
/// Gets or sets the selected target to source icon
/// </summary>
/// <value>The selected target to source icon.</value>
[Parameter]
public string SelectedTargetToSourceIcon { get; set; } = "keyboard_arrow_left";

/// <summary>
/// Gets the final CSS style rendered by the component. Combines it with a <c>style</c> custom attribute.
/// </summary>
Expand Down