|
<SfTooltip ID="Tooltip" Content="@Content" CssClass="customclass" >
<SfButton ID="btn" Content="Show Tooltip"></SfButton>
</SfTooltip>
@code
{
string Content = "Tooltip";
} |
Have just upgraded to 2.4.44 and the bug is back:
CssClass does not come through to the HTML
Mike, We have validated the reported issue(CssClass does not work) in Blazor Tooltip component and unable to reproduce the issue at our end. For your reference, we included the sample with the mentioned version(20.4.44).
We suspect that the issue occurs due to the improper script and style references added to the sample. Some of the breaking changes have been included in our release version 20.1.47. So, you should install the latest individual NuGet package and add script and style references to your sample. Check the release notes below for changes.
Release notes link(Breaking changes) : https://blazor.syncfusion.com/documentation/release-notes/20.1.47?type=all#common
Check out the below mentioned code snippets for your reference.
|
[SfDashboard.csproj] <ItemGroup> … <PackageReference Include="Syncfusion.Blazor.Popups" Version="20.4.0.44" /> <PackageReference Include="Syncfusion.Blazor.Buttons" Version="20.4.0.44" /> <PackageReference Include="Syncfusion.Blazor.Themes" Version="20.4.0.44" /> </ItemGroup>
[_Layout.cshtml] <link rel='nofollow' href="_content/Syncfusion.Blazor.Themes/bootstrap5.css" rel="stylesheet" /> <script src="_content/Syncfusion.Blazor.Core/scripts/syncfusion-blazor.min.js" type="text/javascript"></script>
[OR]
<link rel='nofollow' href=https://cdn.syncfusion.com/blazor/20.4.44/styles/bootstrap5.css rel="stylesheet" /> <script src=https://cdn.syncfusion.com/blazor/20.4.44/syncfusion-blazor.min.js type="text/javascript"></script> |
Sample : https://www.syncfusion.com/downloads/support/directtrac/general/ze/SfTooltip-1918933669.zip
Follow our suggested way and check out the attached sample at your end. If the issue still persists, share the issue replicated video footage or issue replication steps to validate further and provide a prompt solution.
Regards,
Leo Lavanya Dhanaraj
We're currently using version 28.2.11 and it seems, that the bug is back. I added classes to my tooltips:
<SfTooltip Position="Position.BottomCenter" CssClass="inline-tooltip w-auto pe-0">
But in the frontend they're not added.
Hi Mario Maier
We have investigated the reported issue in the latest version of the Tooltip component. Our analysis confirms that the CSSClass is being properly added to the DOM.
For your reference, please find below:
If you're still encountering the issue, could you please:
This will help us reproduce and investigate the matter more effectively.
Thank you for your understanding and cooperation. Please don't hesitate to reach out if you have any further questions.
Regards,
Priyanka K
The example given by Priyanka K breaks for me when increasing the version to 3.1.40
See this link: https://blazorplayground.syncfusion.com/LZBIDurBwXXvzCeL
It still seems broken in the latest version 31.1.20
https://blazorplayground.syncfusion.com/VNhyNuBLwtLKymNJ
It looks like tooltips have broken many times in the past. Why does this is keep breaking?
It seems the tooltip is not appearing in the provided sample. This behavior is attributed to breaking changes introduced in Tooltip Component version 30.1.37. To address this, the `TargetContainer` property can be utilized, allowing the tooltip to function with dynamically created elements or targets outside the Tooltip component. This property is `null` by default. When the target element is not within the Tooltip wrapper, set the `TargetContainer` property to the CSS selector of the target's parent element.
<SfTooltip Target="#sync" TargetContainer="#sync" Content="sync" CssClass="inline-tooltip w-auto pe-0">
</SfTooltip>
<div id="sync">syncfusion</div>
Sample: https://blazorplayground.syncfusion.com/embed/LZLSNkhgsuUBeENz?appbar=true&editor=true&resu…
Documentation reference: Essential Studio for Blazor 2025 Volume 2 Main Release Release Notes