Comments (12)
No, we are not going to change that logic. Even if the result is that no rows are being returned, the grid is then no longer in a Loading state. It is not on us to interpretate if that is a satisfactory result or not.
from fluentui-blazor.
Do you have any other idea to bypass the problem with req.Count as null?
from fluentui-blazor.
I think that is something that needs to be handled on 'your' side. We can't determine what is right or wrong when null is returned.
from fluentui-blazor.
Perhaps there was a small misunderstanding.
I would like to deal with invalid input parameters on "my side" (e.g. req.Count is null) but I can't as after every ItemsProvider call the loading indicator disappears and doesn't open when ItemsProvider called again.
private GridItemsProvider<RowDto> InitialProvider => async req =>
{
try
{
_grid.SetLoadingState(true);
if (req.Count is null) throw new OperationCanceledException();
var results = await new GridCommand(args).Execute(req.CancellationToken);
return GridItemsProviderResult.From(
items: results.Items,
totalItemCount: results.TotalItemCount
);
}
catch (OperationCanceledException ex) {}
return GridItemsProviderResult.From(
items: Array.Empty<RowDto>(),
totalItemCount: -1
);
};
from fluentui-blazor.
The disappearing of the loading indicator is by design. The provider has retuned, so loading is done.
from fluentui-blazor.
So in the case of using the Virtualize parameter, which gives req.Count as null on the first load? Should I use an external loading indicator?
from fluentui-blazor.
No, you should anticipate on that first request returning null. You know that will always be the case.
from fluentui-blazor.
At this moment, I have no way to handle it.
I tried with OnAfterRender, loading flags, etc., but nothing worked.
from fluentui-blazor.
Sorry to hear that. Up until now, there has been no issues/discussions around this. You must have a pretty unique use case.
from fluentui-blazor.
I will make a reproduced example and report the bug issue if it is not a problem.
from fluentui-blazor.
Sure, no problem. But as this is one of the most used (and most complex) components, we will be very careful to not have any breaking changes. So no guarantee that your issue can or will be resolved.
And please create a new issue so we don't have all the bagage from the discussions in this one :)
from fluentui-blazor.
Of course!
from fluentui-blazor.
Related Issues (20)
- feat: Can we provide support for multiple languages HOT 6
- SelectedItemChanged doesn't trigger on first sub item HOT 1
- fix: OnRowClick is always trigger in FluentDataGrid HOT 6
- [FluentSortableList] Fix ability to show more than one line in the template HOT 1
- Fix For: Missing LibraryConfiguring Injection in DesignToken.razor.cs HOT 1
- fix: Fixed + ellipsis cut off in FluentOverflow HOT 11
- Toolbar example preview error HOT 2
- fix: FluentButton doesn't support Appearance.Filled in templates
- Tooltip sample is not displayed over menu HOT 1
- Using SplashScreen HOT 1
- Possible bug in the 4.9.2 javascript HOT 2
- feat: add different types to FluentDatePicker HOT 5
- fix: If FluentNavMenu is shown shown programmatically the CollapsedChildNavigation doesn't work HOT 14
- fix: Accordion in dark mode HOT 1
- Possible bug in 4.9.3 javascript HOT 2
- feat: Add TopBar Component HOT 3
- fix: add Overlay to Splash screen shown by ShowSplashScreenAsync HOT 1
- feat: add Label location control to FluentTextArea HOT 4
- fix: textbox behaviour in fluentsearch in when searching text
- feat: Add support for setting FluentDialog width as the max of two values HOT 1
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 fluentui-blazor.