Comments (6)
<CascadingValue Value=false Name="UsePopoverProvider">
-- this is your problem.
Why are you setting UsePopoverProvider
to false
? You should only need that if you are already registering a PopoverProvider
somewhere else in your code. It's usually registered within the MudThemeProvider
, but your telling the MudThemeProvider
to not register it.
Also, if that's all your class does, there is no real need to make your own class, you just need to define your custom MudTheme and do <MudThemeProvider Theme="MyTheme" IsDarkMode="true"/>
from mudblazor.
@Anu6is This was probably a copy paste error on my part. I have removed this and now it works without any problems. Many thanks for your support.
from mudblazor.
You are most likely missing something in your setup. Since you've stated that you added the render modes globally, the next possible issues is missing the mud providers in your main layout.
from mudblazor.
@Anu6is Yes, I have declared the two lines <MudThemeProvider/>
and <MudDialogProvider/>
in the MainLayout.razor.
from mudblazor.
Can you share a repo link reproducing the issue?
from mudblazor.
@Anu6is I have tried to create a separate project and reproduce the problem. However, the component works there without any problems. Unfortunately, I cannot publish my code.
I have now found out that the source of the problem is with my costum ThemeProvider. It is structured like this:
<CascadingValue Value=false Name="UsePopoverProvider">
<MudThemeProvider Theme="MyTheme" IsDarkMode="true"></MudThemeProvider>
</CascadingValue>
@code {
public static MudTheme MyTheme => new()
{
PaletteDark = new PaletteDark()
{
Primary = "#e30613",
AppbarBackground = "#1a1e21",
Background = "#1a1e21",
TextPrimary = "#e2e2e2",
Secondary = "#039136",
Black = "#151521",
Dark = "#151521",
Tertiary = "#95a5a6",
},
Typography = new Typography()
{
Default = new Default()
{
FontFamily = new[] { "Roboto", "Verdana", "Geneva"}
},
Button = new Button()
{
TextTransform = "None",
FontSize = "0.85rem"
}
}
};
}
I have the following references in the MainLayout:
<MyMudThemeProvider />
(is like the name of the class)
<MudDialogProvider />
<MudSnackbarProvider />
If I reference the standard <MudThemeProvider/>
, the components work.
Do you have any idea what is wrong here?
from mudblazor.
Related Issues (20)
- DataGrid Sticky columns header is not sticky
- MudNavLink icons on mini variant of MudDrawer not staying in the same place when hovering the drawer HOT 1
- DataGrid Performance affected by inline edit
- Appbar overlay IOS Top StatusBar
- Support code generation for Generic components with Type Constraint HOT 11
- DataGrid Form Edit mode not working in .NET 8 HOT 3
- Allow MudDatePicker to bind to non-nullable DateTime field with working validation HOT 9
- MudTextField error state is wrongly set HOT 1
- MudNumericField autocorrects invalid input using wrong decimal separator instead of just validating
- MudTreeViewItem: annoyingly slow opening time when expand is triggered via check box HOT 7
- Docs: TreeView parent checkbox gets unchecked when all subitems are checked HOT 5
- Utilities: Increase max values from `16` HOT 1
- Rework adornments [Multiple, Start+End, Reusable, etc] HOT 20
- Rework component density system HOT 3
- Documentation - installation page is outdated HOT 1
- DropZone: items not layering correctly on touch devices
- DropZone: CanDropClass and NoDropClass not applied on touch device
- ShrinkLabel missing from MudField? HOT 1
- MudDatePicker 7.0.0 Preview width style visual breaking change HOT 3
- Touch events pass through menu items HOT 5
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from mudblazor.