Skip to content

Conversation

@joriverm
Copy link
Contributor

@joriverm joriverm commented Nov 18, 2025

currently our application is having some problems with blazor not liking the anchor of the Table of content items. this has to do with blazor and the url of the application and is not part of radzen, so no worries there :D

however, to prevent blazor's enhanced navigation from screwing up, we need to add an attribute to the TocItem.
dotnet/aspnetcore#52514
dotnet/aspnetcore#8393
dotnet/aspnetcore#51646
etc etc

but we can't add data-enhance-nav="false" unless the TocItem allows for attributes to be set.
this PR implements attributes for the TocItem, but not the full RadzenComponent to not take in as much overhead.

EDIT: i just realised i can fix our issue by setting the attribute on the RadzenToc itself, which implements RadzenComponent & the attributes. Im ok with this being merged or not, but i think it can be useful to have the attributes like class or style

@enchev enchev merged commit 59b1440 into radzenhq:master Nov 18, 2025
1 check passed
/// </summary>
public partial class RadzenTocItem : ComponentBase, IAsyncDisposable
{
/// <summary>
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe it is easier and less code to just inherit from RadzenBlazorComponent - it has Attributes and does the CSS class merging.

Copy link
Contributor Author

@joriverm joriverm Nov 18, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

do i make a new PR with the change? i didn't want to just add all the overhead of the base component without approval ^^;

EDIT: nvm, i saw Vladimir changed it. thanks for the quick response!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants