Giter Club home page Giter Club logo

radzenhq / radzen-blazor Goto Github PK

View Code? Open in Web Editor NEW
3.2K 70.0 721.0 17.55 MB

Radzen Blazor is a set of 70+ free native Blazor UI components packed with DataGrid, Scheduler, Charts and robust theming including Material design and FluentUI.

Home Page: https://www.radzen.com

License: MIT License

Dockerfile 0.02% HTML 30.64% C# 48.50% CSS 3.13% SCSS 13.44% JavaScript 4.18% Liquid 0.10%
blazor asp-net-core blazor-components blazor-application blazor-webassembly datagrid data-grid data-visualization csharp wasm

radzen-blazor's Introduction

Radzen Blazor Components

Radzen Blazor Components

A set of 70+ free and open source native Blazor UI controls.


License - MIT NuGet Downloads Last Commit Github Contributors Radzen Blazor Components - Online Demos Radzen Blazor Components - Documentation

Why choose Radzen Blazor Components?

โœจ Free

Radzen Blazor Components are open source and free for commercial use. You can install them from NuGet or build your own copy from source.

Paid support is available as part of the Radzen Professional subscription.

๐Ÿ’ป Native

The components are implemented in C# and take full advantage of the Blazor framework. They do not depend on or wrap existing JavaScript frameworks or libraries.

Blazor Server and Blazor WebAssembly are fully supported.

๐ŸŒฑ Growing

We add new components and features on a regular basis.

Short development cycle. We release as soon as new stuff is available. No more quarterly releases.

Support exceeding your expectations

๐Ÿ’ฌ Community Support

Everybody is welcome to visit the Radzen Community forum. Join the growing community and participate in the discussions!

๐ŸŽฏ Dedicated Support

The Radzen team monitors the forum threads, but does not guarantee a response to every question. For guaranteed responses you may consider the dedicated support option.

Dedicated support for the Radzen Blazor Components is available as part of the Radzen Professional subscription.

Our flagship product Radzen Blazor Studio provides tons of productivity features for Blazor developers:

  • An industry-leading WYSIWYG Blazor design time canvas
  • Scaffolding a complete CRUD applications from a database
  • Built-in security - authentication and authorization
  • Visual Studio Code and Professional support
  • Deployment to IIS and Azure
  • Dedicated support with 24 hour guaranteed response time

Get started with Radzen Blazor Components

1. Install

Radzen Blazor Components are distributed as a Radzen.Blazor NuGet package. You can add them to your project in one of the following ways

  • Install the package from command line by running dotnet add package Radzen.Blazor
  • Add the project from the Visual NuGet Package Manager
  • Manually edit the .csproj file and add a project reference

2. Import the namespace

Open the _Imports.razor file of your Blazor application and add this line @using Radzen.Blazor.

3. Include a theme

Radzen Blazor components come with five free themes: Material, Standard, Default, Dark, Software and Humanistic.

To use a theme

  1. Pick a theme. The online demos allow you to preview the available options via the theme dropdown located in the header. The Material theme is currently selected by default.
  2. Include the theme CSS file in your Blazor application. Open Pages\_Layout.cshtml (Blazor Server .NET 6), Pages\_Host.cshtml (Blazor Server .NET 7) or wwwroot/index.html (Blazor WebAssembly) and include a theme CSS file by adding this snippet
    <link rel="stylesheet" href="_content/Radzen.Blazor/css/material-base.css">

To include a different theme (i.e. Standard) just change the name of the CSS file:

<link rel="stylesheet" href="_content/Radzen.Blazor/css/standard-base.css">

4. Include Radzen.Blazor.js

Open Pages\_Layout.cshtml (Blazor Server .NET 6), Pages\_Host.cshtml (Blazor Server .NET 7) or wwwroot/index.html (Blazor WebAssembly) and include this snippet:

<script src="_content/Radzen.Blazor/Radzen.Blazor.js"></script>

5. Use a component

Use any Radzen Blazor component by typing its tag name in a Blazor page e.g.

<RadzenButton Text="Hi"></RadzenButton>

Data-binding a property

<RadzenButton Text=@text />
<RadzenTextBox @bind-Value=@text />
@code {
  string text = "Hi";
}

Handing events

<RadzenButton Click="@ButtonClicked" Text="Hi"></RadzenButton>
@code {
  void ButtonClicked()
  {

  }
}

Run demos locally

Use Radzen.Server.sln to open and run demos as Blazor server application or Radzen.WebAssembly.sln to open and run demos as Blazor WebAssembly application. Radzen.sln has reference to all projects including tests.

radzen-blazor's People

Contributors

akorchev avatar alittasakraf avatar bikotoru avatar cosmatevs avatar danrogers99 avatar davebagler avatar djatkinsrealis avatar douglassimaodev avatar enchev avatar ggomarighetti avatar gioeeng avatar glutio avatar javiercampos avatar johanpolak avatar k-sacr avatar mafei1982 avatar marekm294 avatar mpapst avatar msdevcode avatar nielsnocore avatar paulo-rico avatar pianomanjh avatar pigwing avatar sobaka06243 avatar stlufred avatar thedomingo avatar timchen44 avatar vertonghenb avatar viordash avatar yordanov avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

radzen-blazor's Issues

RadzenGrid Header and Column auto-scaling

Describe the bug
While rendering Radzen Grid members, grid headers and columns sizes (width) are not related to each other.
It looks like separate components. Specific header and related column content is not in the same position.

To Reproduce
Steps to reproduce the behavior:

  1. Declare component with binding of TItem
  2. add element as nested in RadzenGrid
  3. add without setting of Width fixed option nested in Columns
  4. add nested in RadzenGridColumn
  5. add many without setting of Width fixed option nested in Columns (for example by using foreach loop
  6. add nested in RadzenGridColumn
  7. run application and display prepared table
  8. Expected behavior
    Expected behavior is to header and columns content be displayed in one vertical position. View should be rendered as Width = Auto setting would be set

    Screenshots
    image

    Desktop:

    • OS: Windows 10 Pro
    • Browser Chrome
    • Version 88.0.4324.182

Blazor menu displays outside of screen when dropdown

When you use the RadzenMenu control, if you align it to the right, when it opens, it shows the menu items outside of the screen.
It would be good if it checked if the menu doesn't fit or it is outside of the screen and open aligned to the other side.

Also it would be good to have a property to choose if we want to open upwards instead of down.

image

Blazor 5.0 server - warning CS1998

Hi,

I tried your solution, created a simple test project directly without adaptation and imported a test DB from SQL server.
There are many warnings when I press RUN.

Then I analyzed the code in Visual Studio and there I also get a lot of "CS1998" warnings:

6f5b59c2738eb4f941d81099502681804b4f3e75

Visual Studio says there is an asynchronous task method, but no waiting time, as can be clearly seen in the generated code:

421e3d2f41913478bc54b9cba63950269814aeec

Any idea to avoid that?

Cheers,
FM

Can't debug WASM with code behind components

Describe the bug
When using RadzenButton, no break points are being hit when using a code behind (ie. MyComponent.razor.cs) instead of having the C# code directly in the razor file in Blazor WASM.

To Reproduce
Steps to reproduce the behavior:

  1. Create MyComponent.razor and add the following code to a razor file:
    <RadzenButton @onclick="IncrementCount" Text="@CurrentCount.ToString()"></RadzenButton>
  2. Create MyComponent.razor.cs, make it partial
  3. Add the following code to MyComponent.razor.cs
public int CurrentCount { get; set; } = 1;

public void IncrementCount(MouseEventArgs e)
{
    CurrentCount++;
}
  1. Set a break point in IncrementCount
  2. Debug the wasm app and navigate to a page containing your component
  3. Click the Button
  4. Note that the breakpoint is not being hit
  5. Change the code in the razor file to the following
    <button @onclick="IncrementCount">@CurrentCount.ToString()</button>
  6. Debug, click the button, note that the break point is hit

Expected behavior
I would expect to be able to hit a break point using Radzen components when using a code behind cs file.

Desktop (please complete the following information):

  • OS: Windows 10 Pro
  • Browser Edge
  • Version 88.0.705.50
  • Visual Studio 2019 16.8.4

Additional context
I also tried in Visual Studio 2019 Preview.

Lazy loading of components if webassembly profile

Is your feature request related to a problem? Please describe.
The download size of the components is 255KB Radzen.Blazor.dll. This is no issue with server side rendering, but adds to bandwidth with stand alone webassembly Blazor clients.

Describe the solution you'd like
Relevant Radzen Blazor components lazy loaded when page is displayed.

Describe alternatives you've considered
No other alternative yet.

Additional context
The following description about lazy loading by Microsoft.

Add optional global search capabillity

Describe the solution you'd like
Add an optional global search box on top of data grid.
It is handy to type some characters in a global search box and the "contains" criteria is applied to all columns.

Example:
image

DataList isn't updating on StateHasChanged

I'm current using the DataList component to show a list of object. It populates correctly, however if I remove an item from the collection and call StateHasChanged the DataList is not updated. However, if I go to a different page, and then go back to the first page, the item is removed as expected.

Is there a work around to force the DataList automatically update the displayed data without having to page?

Radzen Autocomplete doesn't render in Radzen Datagrid FilterTemplate

Describe the bug
Nesting a <RadzenAutoComplete> component inside the <FilterTemplate> of a data grid component results in incorrect rendering.

To Reproduce
Steps to reproduce the behavior:

  1. Create a Radzen Datagrid
  2. Add at least one column and add a filter template.
  3. Add a RadzenAutoComplete component and run the site.
<RadzenGridColumn TItem="ContactGoalViewModel" Property="CompanyName" Title="CLient Agency">
                <FilterTemplate>
                    <RadzenAutoComplete Placeholder="Type to search" Data="agencies" LoadData="SearchAgencies" @bind-Value="CurrentAgency"></RadzenAutoComplete>
                </FilterTemplate>
            </RadzenGridColumn>

Alternatively link your repo with a sample project that can be run.

Expected behavior
The autocomplete component should render and run.

Screenshots
The client agency and primary liaison are using autocomplete components.
image

Desktop (please complete the following information):

  • Browser: Chrome, Chromium Edge, Firefox
  • Version: Radzen 3.1.1
    .NET 5 Blazor Server

Cannot use RadzenComponent.Element in inheritance

Hi guys!
I'm trying to make my oun component inherited from RadzenComponent. Element property has "internal set". So using @ref="@element" generates compile errors.

UPDATE

Is your feature request related to a problem? Please describe.
Cannot use "Element" property in RadzenComponent after inheritance

Describe the solution you'd like
Make protected or public setter there

Describe alternatives you've considered

Additional context

public ElementReference Element { get; internal set; }

UseRowNumberForPaging

Error being generated because "UseRowNumberForPaging" is no longer supported.

Row-number paging is no longer supported. See https://ak.ms/AA6h122 for more information.

When using Radzen development tool 2.57.9 and using a MSSQL database the error is generated and build is stopped.

An error should not be created when trying to run the application generated by the Radzen tool. Since the "UseRowNumberForPaging" is no longer viable, it should be an option for older versions of the app or a way to turn off the Row Number For Paging should be available.

image

Close Notifications using the NotificationService

Is your feature request related to a problem? Please describe.
My issue is not related to a problem, however currently it is only possible to create and Notify a message without manually closing the notification programmatically. This can become a problem when you use the notification to permanently show a status for an async task (such as "Changing status..." or something) .It would be great to hide/close the notification programmatically.

Describe the solution you'd like
I would like to see something like NotificationService.Close(message); or message.Close();

Describe alternatives you've considered
I cannot think of any alternative as async (network) requests don't have a specific duration.

Additional context
I feel like adding a .Close(); method is a basic functionality that would definitely improve the Notification component

Handle inline javascript for Content Security Policy

Some components use inline javascript, for example RadzenUpload uses onchange property on input to execute javascript. For the browser not to block this action you would need to set Content Security Policy to "script-src 'unsafe-inline'" which is bad security practice.

There are two ways of doing this:

  1. Move inline javascript to separate file whenever is possible (Radzen.Blazor.js) (see this post)
  2. If 1. is not possible, set all inline javascript in script-blocks with nonce attribute, using the same Radzen Blazor-nonce across all inline script blocks (see this post)

Hide Up/Down on RadzenNumeric Optional

Describe the solution you'd like
Optionally hide the Up & Down Button on the RadzenNumeric Component.
These are not useful in scenarios where you provide a double as value and the RadzenTextBox does not provide a way to bind a numeric value to it.

I've created a sample implementation and can supply a Pull request.

RadzenGrid Reset() - not clearing second filter in FilterMode.Advanced.

Found a bug where if RadzenGrid FilterMode is set to "FilterMode.Advanced", calling Reset() method (which should clear filters) doesn't clear the second filter. (it clears the filter itself and shows correct records, but doesn't clear the text-field in filter input)

Steps to reproduce the behavior:

  1. Create <RadzenGrid FilterMode="FilterMode.Advanced" ... > ....
  2. Create <RadzenButton @ref ="dataGrid" Click=@ResetData ... />
  3. Create Method ResetData() { dataGrid.Reset() }
  4. Set both filter inputs (advanced filter) of selected column
  5. Click the button to reset filters
  6. Check to see that the second filter wasn't cleared

Expected behaviour:
Calling RadzenGrid.Reset() method clears all filters and their input fields

Screenshots
Before calling Reset() :

image

After calling Reset() :

image

  • OS: Windows 10
  • Chrome 88

Gave up

Spent 15 minutes trying to get this to work and gave up? Why?

Started here... https://razor.radzen.com/get-started

Right off the bat, I'll note, where is the minimal downloadable solution that has performed all these steps? Doesn't exist, OK, not an auspicious start. Step 1 - 5 could provide some additional helpful details, but step 6 is a gem...

Open the Shared/MainLayout.razor file and include <RadzenDialog/>, <RadzenNotification/>, <RadzenContextMenu/> and <RadzenTooltip/>

Include them where? I eventually found this...

https://github.com/radzenhq/radzen-blazor/blob/master/RadzenBlazorDemos/Shared/MainLayout.razor

Kind of gave me an idea, but there's so much other stuff there, i.e. RadzenHeader, that's it not clear where you should just include them.

But Ok, take a guess, include them at the top. Now I'm ready to drop a control onto a page. Let's take RadzenGrid. Bind it to a List and run...

crit: Microsoft.AspNetCore.Components.WebAssembly.Rendering.WebAssemblyRenderer[100]
      Unhandled exception rendering component: Could not find 'Radzen.adjustDataGridHeader' ('Radzen' was undefined).
      Error: Could not find 'Radzen.adjustDataGridHeader' ('Radzen' was undefined).

Please take the default Blazor project, add the ABSOLUTE MINIMUM bootstrap code to get a control running, and upload it somewhere.

Upload (Blazor)

Describe the bug
Upload often fails(CSV)

To Reproduce

Expected behavior
It doesn't fail every time, but sometimes it fails
Also, I don't know if it's related, but the [Controller] has made two requests, and the first time [IFromFile] is null.
When the file upload fails, UploadCompleteEventArgs.RawResponse in the [Completed] event is "empty".

Screenshots
If applicable, add screenshots to help explain your problem.
image

Desktop (please complete the following information):

  • OS: [e.g. iOS]

Server Centos7 client:Windows10

  • Browser [e.g. chrome, safari]

chrome,Edge,IE11

Additional context

Option to disable RadzenMenuItem

I have a RadzenMenu that based on the selected items below I need to enable/disable certain actions that are represented by RadzenMenuItems.

For an example, you can see the "CommandBar with split and disabled buttons" example for the FluentUI CommandBar control.

image

For the solution I would like to have a "Disabled" bool property like the button has so I can enable or disable the menu item.

Alternatively, I could also build up my own menu using buttons and have an option for styling the button similar to the menu. An example for the button would be the "Action Button" or "Command Button" section on the FluentUI Button page.

[Missing documentation] : Dialog service is necessary for RadzenHtmlEditor

Describe the bug
Using RadzenHtmlEditor without configured dialog service results in error Unhandled exception rendering component: Cannot provide a value for property 'DialogService' on type 'Radzen.Blazor.RadzenHtmlEditorLink'. There is no registered service of type 'Radzen.DialogService'.

It is not mentioned in documentation or in sample page.

To Reproduce
Steps to reproduce the behavior:

  1. Add RadzenHtmlEditor
  2. Run app

Expected behavior
it should be mentioned in docs.

Screenshots
If applicable, add screenshots to help explain your problem.

Desktop (please complete the following information):

  • OS: [e.g. iOS]
  • Browser [e.g. chrome, safari]
  • Version [e.g. 22]

Additional context
To make it work use builder.Services.AddScoped<DialogService>(); in Program.cs

Context menu service breaks PanelMenu

Describe the bug
Opening a dialog from a contex menu and then clicking in every part of the page, you will loose your current active page in the Panel menu.

To Reproduce
Open any kind of dialog from a context menu.
Click in any part of your page and you will see in the background your active page in the menu disappearing.

Alternatively link your repo with a sample project that can be run.

Expected behavior
A clear and concise description of what you expected to happen.

Screenshots
If applicable, add screenshots to help explain your problem.

Desktop (please complete the following information):

  • OS: Windows 10
  • Browser Chrome
  • Version 88

Additional context
I saw that the problem does not appear if I change the closeMenuItems function by adding an additional condition testing the menu object:

`closeMenuItems: function (event) {
var menu = event.target.closest('.rz-menu');

//>>
// original line 
//if (!menu) {

// modified line
if (!menu && menu != null) {
//<<

  var targets = document.querySelectorAll(
    '.rz-navigation-item-wrapper-active'
  );

  if (targets) {
    for (var i = 0; i < targets.length; i++) {
      Radzen.toggleMenuItem(targets[i], false);
    }
  }
  document.removeEventListener('click', Radzen.closeMenuItems);
}

},
`

Here a short video :

RadzenCMBug.mp4

Thank you,

Error in demo Dashboard

Describe the bug
Opening the demo Dashboard resulted in the following error:

An error has occurred: Year, Month, and Day parameters describe an un-representable DateTime.. Try reloading your browser.

To Reproduce
Steps to reproduce the behavior:

  1. Download the demo project, build and debug
  2. Click on 'Dashboard' in the resulting web page in January!
  3. See error

Expected behavior
Dashboard should collect github issues data from last month.

Screenshots
image

Desktop (please complete the following information):

  • OS: Windows 10, 64-bit
  • Chrome
  • Version 87.0.4280.141 (Official Build) (64-bit)

Additional context
Issue is caused by this line of code in the GitHubService.cs:

var lastMonth = new DateTime(date.Year, date.Month - 1, 1);

After changing it into:

var lastMonth = new DateTime(date.Year, date.Month, 1);
lastMonth = lastMonth.AddMonths(-1);

it worked as expected.

Basic DropDown box not selecting first item in the list

Describe the bug
A dropdown will not highlight the first item in the list when selected, with filters present the highlight occurs correctly.

To Reproduce
the issue can be see at https://blazor.radzen.com/dropdown on the first dropdown example, select the 1st item then reopen the dropdown. The selected item is not highlighted, try this with any other entry and the highlight occurs correctly.

Expected behavior
highlight the 1st item in the dropdown list

Desktop (please complete the following information):
The issue appears to be browser agnostic, tested in Firefox, Opera, Edge and Chrome.

ContextMenu only opens once in Blazor WASM (PWA)

Describe the bug
In my Blazor WASM PWA project I have implemented the Radzen ContextMenu. When using it, it opens only the very first attempt. Alle later attempts won't open the ContextMenu. It also only works on html elements, not on the RadzenButton for instance.

To Reproduce
Steps to reproduce the behavior:

  1. Unzip the attached project
  2. Start it (I use CTRL-F5 from Visual Studio)
  3. Click in the menu on "Context menu test"
  4. Right click on the html button or one of the table rows
  5. Right click again on the html button or one of the table rows
    6 Refreshing the page makes it work again once
    7 Also notice that the ContextMenu will not show when rightclicking on the RadzenButtons

Here is the reproduction project:
BlazorWASMRadzen.zip

Expected behavior
I expected at step 5 that the context menu would open again

Screenshots
N.a.

Desktop (please complete the following information):

  • OS: Windows 10
  • Browser Chrome
  • Version 87.0.4280.141

Additional context
The sourcecode from this github is working on my machine, but that does not meet my requirements for a Blazor WASM PWA

Radzen Grid - CancelEditRow only works on page 1 of multipage grid.

On a multi-page grid, doing a CancelEditRow only works on page 1, on all other pages, the unselected row is still highlighted.

Code sample:

`
@page "/GridWorks"

@using RazdenTesting.Data
@using Radzen;
@using Radzen.Blazor;
@Inject WeatherForecastService ForecastService

Radzen Test

@if (forecasts == null)

{

Loading...


}
else
{
<RadzenGrid
Count="@count"
AllowPaging="true"
PageSize="@PageSize"
Data="@sortedData"
LoadData="@loaddata"
TItem="WeatherForecast"
AllowSorting="true"
AllowFiltering="true"
RowSelect="@OnRowSelect"
EditMode="DataGridEditMode.Multiple"
@ref="weatherGrid">

    <Columns>
        <RadzenGridColumn
            TItem="WeatherForecast"
            Property="Date"
            Title="Date" >
            <Template Context="data">
                @String.Format("{0:d}", data.Date)
            </Template>                    
        </RadzenGridColumn>
        <RadzenGridColumn
            TItem="WeatherForecast"
            Property="TemperatureC"
            Title="Temp. (C)" >
        </RadzenGridColumn>
        <RadzenGridColumn
            TItem="WeatherForecast"
            Property="TemperatureF"
            Title="Temp. (F)" >
        </RadzenGridColumn>
        <RadzenGridColumn
            TItem="WeatherForecast"
            Property="Summary"
            Title="Summary" >
        </RadzenGridColumn>
    </Columns>
</RadzenGrid>   

}

@code {
private WeatherForecast[] forecasts;
private WeatherForecast[] sortedData;
private int count = 0;
private int PageSize = 10;
private WeatherForecast CurrentSelectedRow;
RadzenGrid weatherGrid;

protected override async Task OnInitializedAsync()
{
    forecasts = await ForecastService.GetForecastAsync(DateTime.Now);

    var args = new LoadDataArgs
    {
        Skip = 0,
        Top = PageSize
    };


   await LoadData(args);
}

async Task LoadData(LoadDataArgs args)
{

    count = forecasts.Count();
    sortedData = forecasts.Skip(args.Skip.Value).Take(PageSize).ToArray();
    await InvokeAsync(StateHasChanged);
    
}
async Task OnRowSelect(WeatherForecast row)
{
    if (CurrentSelectedRow == null)
    {
        CurrentSelectedRow = row;
        await weatherGrid.EditRow(row);
        return;
    }

    // skip all of this if the same row is being selected.
    if (row == CurrentSelectedRow)
    {
        // make sure it's in edit mode
        if (!weatherGrid.IsRowInEditMode(CurrentSelectedRow))
        {
            await weatherGrid.EditRow(row);
        }
        return;
    }

    weatherGrid.CancelEditRow(CurrentSelectedRow);
    CurrentSelectedRow = row;
   // await weatherGrid.EditRow(row);
    await InvokeAsync(StateHasChanged);
}

}
`

New "Badge" component

Could you add a Badge component?'

Small numerical value or status descriptor for UI elements.

like below shown to us.

Badge component

After change the culture, the months in DatePicker will not be localized (Blazor WASM).

Describe the bug:
After change the culture, the months in DatePicker will not be localized without reload the page.
There were no problems during the culture change in version 2.18.3.
In the version last version the component actually changes the date format according to the language, but the months are not translated until after the page is reloaded.

This problem appeared in version 2.18.4 and still exists until the current version "3.0.1"

To Reproduce
Video: https://drive.google.com/file/d/1lTVuYMal2D_vpPc7vCtcrogPcBaWShK3/view?usp=sharing

Expected behavior:
The months should be translated without reload the page (just like version 2.18.3)

Screenshots
Same video in "To Reproduce"

Desktop:
OS: Windows 10
Browser: Chrome
Version: 87.0.4280.141 (Official Build) (64-bit)

Slide out panels

**Is your feature request related to a problem?
We have a complex creation scenario that will span multiple pages and need to solve the problem in all platforms ideally with one implementation

Describe the solution you'd like
Ideally this would be solved with side panels

Describe alternatives you've considered
Fluentui web panels

Additional context
https://developer.microsoft.com/en-us/fluentui#/controls/web/panel

Grid with Multi-Select (similar to SyncFusion or Telerik)

**Is your feature request related to a problem?
Yes. I have a requirement to display data in a table grid and allow users to multi-select specific rows to take an action on.

Describe the solution you'd like
Similar to the screenshot below, I'd like the ability to either left click each row in the row itself, or via a check box button, Ideally shift and control click would be supported as well for selection sections quickly. Another thing that is commonly missing in multiselect is how to handle paging. This doesn't need to be solved in the first iteration, but I do want to call it out. Typically "select all" ignores the filets you have placed on the data, ideally select all would honor the filters.

Describe alternatives you've considered
Telerik or SyncFusion

Additional context

image

Incorrect behavior after editing inserted item (DataGrid Inline Editing)

Describe the bug
The RowCreate callback is executed instead of RowUpdate on the most recent previously-inserted row when CancelEditRow or UpdateRow is called during subsequent editing.

To Reproduce
Steps to reproduce the behavior:

  1. In a DataGrid with Inline editing, add a new row and save it.
  2. Edit the same row.
  3. Click Save or Cancel.

Expected behavior
After step 1, the RowCreate callback is executed as expected. However, after step 3, the RowCreate callback is again executed. I would expect the RowEdit callback to be called at this point.

Screenshots

Desktop (please complete the following information):

  • OS: Windows 10
  • Browser Chrome
  • Version 87

Additional context
It appears that itemToInsert is not being cleared after step 1.

ColorPicker, Cursor from color Slider not working correctly (WASM)

Describe the bug
The cursor on the color slider doesn't move...the color change but the cursor is always on the initial position (on the left side of the slider)

To Reproduce
Steps to reproduce the behavior:

  1. Create a ColorPicker component
  2. Try to pick a color using the Color Slider
  3. See that the cursor doesn't move but the color change

Expected behavior
The cursor position should move as you pick the color

Screenshots
image

Desktop (please complete the following information):

  • OS: Windows 10
  • Browser: Edge 88.0.705.68
  • Version: 3.0.10

Additional context
On version 2.18.XX it was working good.

RazenGrid in-line edit drops edit mode when checkbox changed

Describe the bug
When using the RadzenGrid in-line edit functionality, if you use any sort of Checkbox control, the edit mode gets switched off as soon as the value is changed, but the changes don't save. In order to save it, you have to re-enable edit mode for the row, then save changes to push them up to the server.
This only happens the first time edit mode is triggered on the page. After the first time it ends edit mode, it will function normally.

To Reproduce
Steps to reproduce the behavior:

  1. Create a component using RadzenGrid
  2. Use in-line editing, create an EditTemplate for a column that is a boolean property, use either InputCheckbox or RadzenCheckbox
  3. Enable edit mode in browser and change the state of the property. Edit mode will stop and server never receives new info.

Alternatively link your repo with a sample project that can be run.

Expected behavior
Allow boolean checkboxes in inline editing.

Screenshots
image
image

Desktop (please complete the following information):

  • OS: Windows 10 20H2
  • Browser: Edge
  • Version 88.0.705.74 (Official build) (64-bit)

Additional context
Working around this using a dropdown, but would prefer to use a checkbox.

Table support in HtmlEditor

Is your feature request related to a problem? Please describe.
Table support in htmlEditor is currently missing.

Describe the solution you'd like
Adding tables, adding/deleting rows and columns. (e.g. like ckeditor )

image

RadzenDropDownDataGrid async LoadData and async EF Core hangs

Describe the bug
RadzenDropDownDataGrid with stopps to work when used as async and you call async Entity Framework methods or asnyc methods from the userManager (asp.net identity) (that uses async EF calls under the hood).
This happens only when using PostgreSQL or SQL Server as the datasource. When using Memory or SQLite it works.
The first load is successful. When you start typing and trigger the filtering it is stuck at var isAdmin = await _userManager.IsInRoleAsync(user, "admin"); in the sample, it would be also stuck at any async EF Core call ex. var someRole = await _ctx.Roles.FirstAsync();.
No exceptions are thrown.
And the whole blazor app hangs (you have to hard-refresh it)
If you run that part Synchronous it works.

@page "/experiments"
@using System.Linq.Dynamic.Core

<h3>Experiments</h3>

<RadzenDropDownDataGrid TValue="string" LoadData="@LoadData" AllowFiltering="true" AllowClear="true" AllowSorting="false" FilterCaseSensitivity="FilterCaseSensitivity.CaseInsensitive"
                        Data=@employees Count="@count" TextProperty="Name" ValueProperty="Name"
/>
using Microsoft.AspNetCore.Components;
using Microsoft.AspNetCore.Http;
using Microsoft.AspNetCore.Identity;
using Radzen;
using System.Collections.Generic;
using System.Linq;
using System.Linq.Dynamic.Core;
using System.Security.Claims;
using System.Threading.Tasks;

namespace RadzenStrangeBehaviour.Pages
{
    public partial class Experiments
    {
        [Inject] private UserManager<IdentityUser> _userManager { get; set; }
        [Inject] private IHttpContextAccessor _httpCtx { get; set; }
        private string UserId => _httpCtx.HttpContext?.User?.FindFirstValue(ClaimTypes.NameIdentifier);

        public class Emp
        {
            public string Name { get; set; }
            public string LastName { get; set; }
        }

        private int count = 0;
        private List<Emp> employees = new();

        private List<Emp> query = new List<Emp>(){
            new Emp{Name = "Andrej", LastName = "A"},
            new Emp{Name = "Adrian", LastName = "A"},
            new Emp{Name = "Alex", LastName = "E"},
            new Emp{Name = "Brane", LastName = "C"},
            new Emp{Name = "Bogdan", LastName = "D"},
            new Emp{Name = "Boio", LastName = "Z"},
            new Emp{Name = "Cene", LastName = "Y"},
            new Emp{Name = "Doris", LastName = "X"}};

        protected override async Task OnInitializedAsync()
        {
            await LoadData(new LoadDataArgs() { Skip = 0, Top = 5 });
        }

        private async Task LoadData(LoadDataArgs args)
        {
            var userId = UserId;
            var user = _userManager.Users.SingleOrDefault(u => u.Id == userId);

            var isAdmin = await _userManager.IsInRoleAsync(user, "admin"); // when you
            //var isAdmin = AsyncHelper.RunSync<bool>(() =>    _userManager.IsInRoleAsync(user, "admin") ); // <-this works
            var q = query.AsQueryable();
            if (!string.IsNullOrEmpty(args.Filter))
            {
                q = q.Where(x => x.Name.ToLower().Contains(args.Filter.ToLower()));
            }

            if (!string.IsNullOrEmpty(args.OrderBy))
            {
                q = q.OrderBy(args.OrderBy);
            }

            count = q.Count();
            employees = q.Skip(args.Skip.Value).Take(args.Top.Value).ToList();
            await InvokeAsync(StateHasChanged);
        }
    }
}

To Reproduce
A template project is created here:
https://github.com/zerox981/RadzenStrangeBehaviour
You need to change the connection string to your SQL server.
Then login with admin@local : Changeme1!
And visit /experiments & try to filter the dropdown.

Expected behavior
RadzenDropDownDataGrid would get filtered.
Blazor app would continue to function normally.

Desktop (please complete the following information):

  • OS: Windows 10
  • Browser Chrome 89, Firefox 86.0.1

Allow Dialog/Modal Re-rendering of fragments

Use case: Using dynamic inline renderfragments with dialog/modal and desire the ability to trigger re-rendering of the dialog/modal either through direct invocation/event:

<RadzenDialog @ref="_dialogComponent" />

@ code {
    RadzenDialogComponent _dialogComponent;

    public void ActionTriggeringAChangeToFragment()
    {
        _dialogComponent.Refresh();
    }
}

where Refresh() would pretty much be a call to InvokeAsync(StateHasChanged);
or accept a delegate/callback argument into the DialogService.OpenAsync that allows the caller to request a re-rendering..such as Service.Refresh += () => StateHasChanged(); for the dialog.

Not super well versed in blazor but can do a PR if this is desirable

DataGrid FilterTemplate not working

Describe the bug
I added a FilterTemplate with a dropdown to a column in a DataGrid for a string property but the filter is never applied.

To Reproduce

  1. Add RadzenGrid which allows filtering
  2. Add a filter template with a drop down to one of the columns with a string value
  3. Run the app and attempt to filter using the drop down
  4. Notice that no filtering has been applied.

The zip file contains an mp4 which shows the filter not working.
filter not working.zip

Here is my code:

<RadzenGrid 
            AllowFiltering="true"
            FilterCaseSensitivity="FilterCaseSensitivity.CaseInsensitive"
            FilterMode="FilterMode.Advanced"
            AllowColumnResize="true"
            Count="@Count"
            Data="@Campaigns"
            LoadData="@LoadData"
            AllowSorting="true"
            AllowPaging="true"
            PageSize="100"
            TItem="CampaignListViewModel"
            ColumnWidth="200px">

    <Columns>
        <RadzenGridColumn TItem="CampaignListViewModel">
            <Template>
                <RadzenButton Icon="edit" Size="ButtonSize.Small">
                </RadzenButton>
            </Template>
        </RadzenGridColumn>
        <RadzenGridColumn TItem="CampaignListViewModel" Property="CampaignName" Title="Campaign Name" />
        <RadzenGridColumn TItem="CampaignListViewModel" Property="ClientName" Title="Client Name" />
        <RadzenGridColumn TItem="CampaignListViewModel" Property="Status" Title="Status">
            <FilterTemplate>
                <RadzenDropDown @bind-Value="@SelectedStatusFilter" TextProperty="Key" ValueProperty="Value" Style="width:100%"
                                Data="@StatusFilters.Select(kv => new { Key = kv.Key, Value = kv.Value })" />
            </FilterTemplate>
        </RadzenGridColumn>
        <RadzenGridColumn TItem="CampaignListViewModel" Property="ResearchStatus" Title="Research Status" />
        <RadzenGridColumn TItem="CampaignListViewModel" Property="ResponseGoal" Title="Response Goal" />
    </Columns>
</RadzenGrid>
public string SelectedStatusFilter { get; set; }

public IEnumerable<KeyValuePair<string, string>> StatusFilters => new[]
{
    new KeyValuePair<string, string>("Active", "Active"),
    new KeyValuePair<string, string>("Inactive", "Inactive")
};

Expected behavior
I'd expect the filter to be applied

Screenshots
image
image
image

Desktop (please complete the following information):

  • OS: Window 10 Pro
  • Browser Edge, Chrome
  • Version Edge: 88.0.705.63; Chrome: 88.0.4324.150

Additional context
Add any other context about the problem here.

DropDown first item does not get marked as Active or Selected (WASM)

You can observe this in provided example

https://blazor.radzen.com/dropdown

How to check

  1. click DropDown to open drop-down menu
  2. Select second item from drop-down menu
  3. open drop-down menu again the second item will be highlighted blue
  4. now select first item from drop-down menu
  5. if you open drop-down menu again the first item does not get highlighted but the previously selected item is highlighted
  6. This behavior is only observed in first DropDown in which custom data is selected using Select method

https://github.com/radzenhq/radzen-blazor/pull/22#issue-557223715

Is your feature request related to a problem? Please describe.
A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]

Describe the solution you'd like
A clear and concise description of what you want to happen.

Describe alternatives you've considered
A clear and concise description of any alternative solutions or features you've considered.

Additional context
Add any other context or screenshots about the feature request here.

Make "orderBy" public in RadzenGrid (or some way of setting the initial orderby status)

Is your feature request related to a problem? Please describe.
I can't seem to set the initial state of the sorting on columns. In our "search" pages (where we use the grid, mainly), we store the "search model" where we save the current page, search form status, etc.

We'd like to also store the sorting on the grid (we use the LoadData event). However, there's an orderBy property from where the sorting state is stored, but it's private (it's also what the column header template queries to draw its icon), so we can't modify it.

You have the OrderBy and OrderByDescending methods which set the property, but they also set the current page to 0 (they set Skip to 0) and immediately request a reload... so setting the current page number and the sorting state doesn't seem to be possible without initiating several LoadData requests.

It's of course hackable if you know what you are doing (or we can just copy the source code and modify), but this should be able to be native to the component, in our oppinion.

Describe the solution you'd like
Either make orderBy public, or make it a [Parameter] property which can be set on initialization without necessarily invoking a reload (or set the page to first page).

Notice that if making it a parameter it would clash with the OrderBy method, so it should be named differently

If you need it, I offer myself to do the PR if needed, as long as you decide what we should call the public property (which again, can't be OrderBy because there's a method named like that)

Cannot read property 'removeChild' of null on ContextMenu usage while navigating away to a page which has other PageLayout

Describe the bug
When using a ContextMenu on a regular button (maybe also on RadzenButton, did not test) I'm getting an error when navigating away to a Page where PageLayout is set to a minimal page layout (for printing)

To Reproduce
Steps to reproduce the behavior:

  1. Unzip attached project BlazorPrintCSSwithRadzen.zip
  2. Press CTRL-F5 (from Visual Studio)
  3. Rightclick on first button to see that contextmenu navigation is working to default Counter page
  4. Rightclick on second button to see that contextmenu navigation is NOT working to default print page

Expected behavior
Contextmenu always working while navigating away to print page

Screenshots
n.a.

Desktop (please complete the following information):

  • OS: Windows 10
  • Browser: Chrome
  • Version: 88.0.4324.104

Additional context
Full error saved from Chrome Developer tools
localhost-1611605562122.log

blazor.radzen.com doesn't force HTTPS.

Describe the bug
The demo website at https://blazor.radzen.com/ allows https to be disabled.

To Reproduce
Edit the address bar, remove https:// and press enter. The site will load over http.

Additionally, the websockets connection will also be unecrypted:
image

Clicking on the Source button of a demo window will result in an error due to the insecure connection:
image

Expected behavior
The server should be served over https.

Drag and drop sortable components

Browsing through your site I don't see any kind of sortable component via drag and drop. We currently use Sortable.js in another project and would like the same functionality in Blazor. I have yet to find any obvious components that support this out of the box. Just curious if you provide anything like this or would consider adding it?

DataGrid : ContextMenu

Hello,

Is there a way to add a "ContextMenu" on the DataGrid component? With the possibility to retrieve the current cell/data on which the "contextmenu" is opening?

Best Regards,

Issue in DatePicker

Describe the bug
Wrong behavior by click on months / years dropdowns.

To Reproduce
Steps to reproduce the behavior:

  1. Go to: https://blazor.radzen.com/datepicker
    image
  2. Click on DatePicker icon to pick a date.
    image
  3. Click on months drowpdown (do not select any month).
    image
  4. Select any Day
  5. The DatePicker will be closed
  6. See error: Months dropdown remines open
    image

Year dropdown has same issue.

Expected behavior
All dropdowns (months/years could be closed when select a day.

Desktop (please complete the following information):

  • OS: Windows 10
  • Browser: Chrome
  • Version: 87.0.4280.141 (Official Build) (64-bit)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.