Comments (7)
Oh, no. The culprit seems to be a conflict with CodeBeam.MudBlazor.Extensions
. I have attached a .zip file containing a test application.
TestApp.csproj
<PackageReference Include="CodeBeam.MudBlazor.Extensions" Version="6.5.6" />
Program.cs
using MudBlazor.Extensions;
using MudBlazor.Services;
using MudExtensions.Services; // <-- hooking in CodeBeam.MudBlazor.Extensions causes the exception; comment out this line, and everything is fine
var builder = WebApplication.CreateBuilder(args);
builder.Services.AddHttpContextAccessor();
builder.Services.AddRazorPages();
builder.Services.AddServerSideBlazor();
builder.Services.AddMudServices();
builder.Services.AddMudExtensions();
var app = builder.Build();
app.UseDeveloperExceptionPage();
app.UseHttpsRedirection();
app.UseStaticFiles();
app.UseRouting();
app.MapBlazorHub();
app.MapFallbackToPage("/_Host");
app.Run();
from mudblazor.extensions.
I will have a look on it. Bacause of another bug i have overwritten IDialogService because MudBlazor dindtn have an accessable jsRuntime in the DialogService. Maybe i can ask them if they can add a property to get the JSRuntime.
But for your problem i hopefully find a quicker solution. As this problem also present if you continue to call InitializeMudBlazorExtensionsAsync ?
from mudblazor.extensions.
Thanks for having a look, absolutely not a hurry or a priority. Yes, we are still calling InitializeMudBlazorExtensionsAsync. We tried not calling it and it seemed we then needed to pass JSRuntime in the options…but I think it resulted in the same exception.
from mudblazor.extensions.
Problem is you didnt have called AddMudExtensions(); from my package. Becuase you have added using of CodeBeam you called the codebeam AddMudExtensions(); (Same name but different method). However to avoid this you have 2 options. You can call it without extension invocation like this
MudBlazor.Extensions.ServiceCollectionExtensions.AddMudExtensions(builder.Services);
Or you just replace the line builder.Services.AddMudServices();
with builder.Services.AddMudServicesWithExtensions();
from mudblazor.extensions.
Thank you! Yes, both of those options appear to work:
Option 1:
using MudBlazor.Extensions;
using MudBlazor.Services;
using MudExtensions.Services;
// this works:
builder.Services.AddMudServices();
builder.Services.AddMudExtensions();
MudBlazor.Extensions.ServiceCollectionExtensions.AddMudExtensions(builder.Services);
Option 2:
using MudBlazor.Extensions;
//using MudBlazor.Services; // <-- not needed
using MudExtensions.Services;
// this works:
builder.Services.AddMudExtensions();
builder.Services.AddMudServicesWithExtensions();
I thought we were running into an issue with Option 2 due to having a Codebeam MudSelectExtended
component on the dialog, but it was because we had not included AddMudExtensions()
as well as AddMudServicesWithExtensions
.
(Honestly, we would prefer to use your MudExChipSelect
component instead (and then we could get rid of Codebeam completely to minimize these kinds of issues), but we have run into problems being able to consistently be able to get focus into the Filter textbox...perhaps I will open another issue for that, if you are interested...I have updated the TestApp.zip to have dialogs with both components.)
Off to buy you a well-deserved cup of coffee. I very much appreciate all of your work and attention. All the best.
from mudblazor.extensions.
I will have a look at it. I know MudBlazor have had a bug and it was solved. You can see it here its working https://cae4f752.mudblazor-extensions.pages.dev/chip-select but now it looks like the Bug is back and now here its no more working https://www.mudex.org/chip-select. But I didnt changed anything in MudExChipSelect or dependent logic.
Maybe I need to rebuild the chipselect. However can I then close this issue? For the chip select you can create a new one.
from mudblazor.extensions.
Yes, sorry, of course. Closing this issue.
from mudblazor.extensions.
Related Issues (20)
- Out dated Blazored.FluentValidation HOT 1
- [Bug]: Getting Microsoft.JSInterop.JSException: 'Cannot read properties of null (reading 'innerText') when trying to show a dialog HOT 2
- [Bug]: Dialogs Stop Working on 2nd client HOT 10
- [Bug]: MudExChipSelect focus issue HOT 4
- [Bug]: MudExUploadEdit totally breaks application. HOT 5
- [Bug]: FileDisplayZip styles isn't applied until you refresh(?) the component HOT 4
- [Bug]: Multiple non-modal dialogs closing issue HOT 2
- [Bug]: MudExFileDisplay won't load file from Stream HOT 22
- [Bug]: no value for property MudExConfiguration for MudExFileDisplayZip HOT 8
- [Bug]: Dialog flickers before actual showing animation HOT 5
- [Bug]: Unable to resolve service for type 'System.Net.Http.HttpClient' while attempting to activate 'MudBlazor.Extensions.Services.MudExFileService' HOT 3
- Ability to click drop are to upload file HOT 1
- Loading icon for files while uploading HOT 2
- Add MudBlazor form validation integration to MudExUploadEdit HOT 2
- [Bug]: MudExPopover does not appear to properly dispose of JS click event listener when re-rendering the component HOT 5
- [Bug]: MudExUploadEdit Crashes Dialogs HOT 2
- Callback for when data is available for files in MudExUploadEdit HOT 2
- Add more descriptive code samples HOT 3
- MudExObjectEditForm: text (string) RenderWith dropdown (select) HOT 4
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.extensions.