component parameter 'Text' should not be set outside of its component
hello here is your demo side bar

the green under line says:
component parameter 'Text' should not be set outside of its component. so do other green under lines.
please help how if possible to fix this. thank you.
SIGN IN To post a reply.
3 Replies
SD
Saranya Dhayalan
Syncfusion Team
March 27, 2020 10:47 AM UTC
Hi Aleqsandre,
Thank you for contacting Syncfusion support
We have checked your reported warnings and we have planned to provide option for defining the menu item properties in tag level to resolve your warnings, which will be included in our Essential studio Volume 2, 2020 release and appreciate your patience until then. You can track the status of this feature using below link.
Regards,
Saranya D
SH
Sven H
November 16, 2020 07:54 PM UTC
Hi
I saw that https://www.syncfusion.com/feedback/9230/need-to-provide-tag-helper-support-menu-item-property-in-menu has been released in version 18.3.0.35. Is there some documentation what exactly this feature is about and how it can be used to avoid the warnings saying '... should not be set outside of its component'?
Thanks
Sven
MK
Mohan Kumar Ramasamy
Syncfusion Team
November 17, 2020 06:52 AM UTC
Hi Sven,
We have checked your reported query. We can resolve warning errors using tag directive. We can render Menu component using Tag directive. Please refer below code snippets.
|
@page "/"
@using Syncfusion.Blazor.Navigations
<div class="control-section">
<div class="menu-control">
<SfMenu TValue="MenuItem">
<MenuItems>
<MenuItem Text="File" IconCss="em-icons e-file">
<MenuItems>
<MenuItem Text="Open" IconCss="em-icons e-open"></MenuItem>
<MenuItem Text="Save" IconCss="em-icons e-save" Disabled="false"></MenuItem>
<MenuItem Separator="true"></MenuItem>
<MenuItem Text="Exit"></MenuItem>
</MenuItems>
</MenuItem>
<MenuItem Text="Edit" IconCss="em-icons e-edit">
<MenuItems>
<MenuItem Text="Cut" IconCss="em-icons e-cut"></MenuItem>
<MenuItem Text="Copy" IconCss="em-icons e-copy"></MenuItem>
<MenuItem Text="Paste"></MenuItem>
</MenuItems>
</MenuItem>
<MenuItem Text="View">
<MenuItems>
<MenuItem Text="Toolbars">
<MenuItems>
<MenuItem Text="Menu Bar"></MenuItem>
<MenuItem Text="Bookmarks Toolbar"></MenuItem>
<MenuItem Text="Customize"></MenuItem>
</MenuItems>
</MenuItem>
<MenuItem Text="Zoom">
<MenuItems>
<MenuItem Text="Zoom In"></MenuItem>
<MenuItem Text="Zoom Out"></MenuItem>
<MenuItem Text="Reset"></MenuItem>
</MenuItems>
</MenuItem>
<MenuItem Text="Full Screen"></MenuItem>
</MenuItems>
</MenuItem>
<MenuItem Text="Tools">
<MenuItems>
<MenuItem Text="Spelling & Grammar"></MenuItem>
<MenuItem Text="Customize"></MenuItem>
<MenuItem Separator="true"></MenuItem>
<MenuItem Text="Options"></MenuItem>
</MenuItems>
</MenuItem>
<MenuItem Text="Help"></MenuItem>
</MenuItems>
</SfMenu>
</div>
</div>
|
For your reference we have prepared a sample based on this, please refer below sample link.
Sample Link: https://www.syncfusion.com/downloads/support/forum/152760/ze/MenuBarTagDirectiveSupport1281531363
Please let us know, if you need any further assistance.
Regards,
Mohan kumar R
SIGN IN To post a reply.
- 3 Replies
- 4 Participants
-
AL Aleqsandre
- Mar 26, 2020 08:16 PM UTC
- Nov 17, 2020 06:52 AM UTC