Opening a dialog panel with a render fragment? #2185
-
Hi folks, Our team is new to Fluent, and we've been struggling a bit with the way that the ShowPanel methods (https://www.fluentui-blazor.net/Panel) work as opposed to the the standard ShowDialog methods (https://www.fluentui-blazor.net/Dialog) which seem to offer a bit more flexability. In particular, we were trying to find a way to display a single component within a panel using a render fragment. I did some digging through the source to see how the ShowDialog methods work and discovered all that the ShowPanel methods seem to be doing is calling ShowDialog and then adding in the DialogType and Alignment parameters to the DialogParameters object. As it turns out it seems we can just use the more flexible ShowDialog methods (including the RenderFragment overload) instead of the ShowPanel methods by simply feeding in the DialogType and Alignment parameters. So, my questions are: Thanks kindly, John Sheridan |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 2 replies
-
Q1 - Yes, that is a kosher way of doing that. We created the ShowPanel variants as convenience methods to make using panels a bit easier. As you found, it all calls the same code in the end. Q2 - Yes, we can update those docs to make this clearer |
Beta Was this translation helpful? Give feedback.
Q1 - Yes, that is a kosher way of doing that. We created the ShowPanel variants as convenience methods to make using panels a bit easier. As you found, it all calls the same code in the end.
Q2 - Yes, we can update those docs to make this clearer