mirror of
https://github.com/ionic-team/ionic-framework.git
synced 2025-08-15 17:42:15 +08:00
fix(react): loading layout is correct with no message (#26222)
Resolves #26219
This commit is contained in:
@ -18,7 +18,7 @@ export function useIonLoading(): UseIonLoadingResult {
|
||||
|
||||
const present = useCallback(
|
||||
(
|
||||
messageOrOptions: string | (LoadingOptions & HookOverlayOptions) = '',
|
||||
messageOrOptions: string | (LoadingOptions & HookOverlayOptions) = {},
|
||||
duration?: number,
|
||||
spinner?: SpinnerTypes
|
||||
) => {
|
||||
@ -26,7 +26,7 @@ export function useIonLoading(): UseIonLoadingResult {
|
||||
return controller.present({
|
||||
message: messageOrOptions,
|
||||
duration,
|
||||
spinner: spinner ?? 'lines',
|
||||
spinner,
|
||||
});
|
||||
} else {
|
||||
return controller.present(messageOrOptions);
|
||||
|
Reference in New Issue
Block a user