Skip to content

Commit

Permalink
added loading indicator when waiting for data
Browse files Browse the repository at this point in the history
fixes: keycloak#35874

Signed-off-by: Erik Jan de Wit <[email protected]>
  • Loading branch information
edewit committed Dec 13, 2024
1 parent f12fe05 commit e670f5d
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion js/apps/admin-ui/src/page/PageHandler.tsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,10 @@
import ComponentRepresentation from "@keycloak/keycloak-admin-client/lib/defs/componentRepresentation";
import ComponentTypeRepresentation from "@keycloak/keycloak-admin-client/lib/defs/componentTypeRepresentation";
import { useAlerts, useFetch } from "@keycloak/keycloak-ui-shared";
import {
KeycloakSpinner,
useAlerts,
useFetch,
} from "@keycloak/keycloak-ui-shared";
import { ActionGroup, Button, Form, PageSection } from "@patternfly/react-core";
import { useState } from "react";
import { FormProvider, useForm } from "react-hook-form";
Expand Down Expand Up @@ -76,6 +80,9 @@ export const PageHandler = ({
}
};

if (!id) {
return <KeycloakSpinner />;
}
return (
<PageSection variant="light">
<Form
Expand Down

0 comments on commit e670f5d

Please sign in to comment.