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

[Docs] Make MenuProvider message more prominent #2792

Merged
merged 1 commit into from
Oct 11, 2024
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
13 changes: 6 additions & 7 deletions examples/Demo/Shared/Pages/Menu/MenuPage.razor
Original file line number Diff line number Diff line change
Expand Up @@ -35,16 +35,15 @@
Fluent UI design system.
</p>

<div>
<div><strong>FluentMenuProvider</strong></div>
<div class="demopanel" style="padding: 1rem; margin-bottom: 1rem;">
<h5>FluentMenuProvider</h5>
<p>
With version 4.9.4 of the library, we introduced a <code>FluentMenuProvider</code>. The <code>FluentMenu</code> component has been updated to use this provider.
The <code>&lt;FluentMenuProvider /&gt;</code> is a new component to be placed at the <b>bottom</b> of your HTML page (like the other <b>Providers</b>),
which renders all menus (and menu items) at the provider location in the HTML structure. This allows for menus to appear <b>on top</b> other components.
With version 4.9.4 of the library, we introduced the <code>FluentMenuProvider</code> component. The Menu component has been updated to use this provider.
The <code>&lt;FluentMenuProvider /&gt;</code> needs to be placed at the <b>bottom</b> of your HTML page (just like the other <b>...Providers</b> components).
It will renders all menus (and menu items) at the provider location in the HTML structure. This allows for menus to appear <b>on top</b> other components.
</p>
<p>
You can disable this feature by adding the <code>UseMenuService="false"</code> attribute.
In this case, the menu is drawn at the location of your HTML code.
You can disable this feature by adding the <code>UseMenuService</code> parameter (with a value of "false") to you FluentMenu component. In this case, the menu will be rendered at the location it is placed at in the page.
</p>
</div>

Expand Down
11 changes: 11 additions & 0 deletions examples/Demo/Shared/Pages/MenuButton/MenuButtonPage.razor
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,17 @@
an <code>Items</code> parameter as well as manually as the <code>ChildContent</code> (at the same time).
</p>

<div class="demopanel" style="padding: 1rem; margin-bottom: 1rem;">
<h5>FluentMenuProvider</h5>
<p>
With version 4.9.4 of the library, we introduced the <code>FluentMenuProvider</code> component. The MenuButton component has been updated to use this provider.
The <code>&lt;FluentMenuProvider /&gt;</code> needs to be placed at the <b>bottom</b> of your HTML page (just like the other <b>...Providers</b> components).
It will renders all menus (and menu items) at the provider location in the HTML structure. This allows for menus to appear <b>on top</b> other components.
</p>

</div>


<h2 id="example">Example</h2>

<DemoSection Component="typeof(MenuButtonAccentColor)" Title="MenuButton to select accent color" />
Expand Down
Loading