diff --git a/src/assets/documentation/documentation-links.json b/src/assets/documentation/documentation-links.json
index a3e4b242..20bfd838 100644
--- a/src/assets/documentation/documentation-links.json
+++ b/src/assets/documentation/documentation-links.json
@@ -85,6 +85,20 @@
"url": "https://access.redhat.com/documentation/en-us/red_hat_enterprise_linux/9/html/managing_idm_users_groups_hosts_and_access_control_rules/managing-user-accounts-using-the-idm-web-ui_managing-users-groups-hosts#deleting-users-in-the-idm-web-ui_managing-user-accounts-using-the-idm-web-ui"
}
],
+ "stage-users-settings": [
+ {
+ "name": "Managing user accounts",
+ "url": "https://access.redhat.com/documentation/en-us/red_hat_enterprise_linux/9/html/managing_idm_users_groups_hosts_and_access_control_rules/managing-user-accounts-using-the-idm-web-ui_managing-users-groups-hosts"
+ },
+ {
+ "name": "Adding a certificate mapping rule",
+ "url": "https://access.redhat.com/documentation/en-us/red_hat_enterprise_linux/9/html/managing_certificates_in_idm/conf-certmap-idm_managing-certificates-in-idm#proc-add-maprule-webui_conf-certmap-for-users-in-idm"
+ },
+ {
+ "name": "Adding certificate mapping data to a user entry",
+ "url": "https://access.redhat.com/documentation/en-us/red_hat_enterprise_linux/9/html/managing_certificates_in_idm/conf-certmap-idm_managing-certificates-in-idm#proc-add-certmapdata-to-user-webui_conf-certmap-for-users-in-idm"
+ }
+ ],
"preserved-users": [
{
"name": "Deleting users",
diff --git a/src/components/UsersSections/UserSettings.tsx b/src/components/UsersSections/UserSettings.tsx
index 0cd6efc5..ad956022 100644
--- a/src/components/UsersSections/UserSettings.tsx
+++ b/src/components/UsersSections/UserSettings.tsx
@@ -100,7 +100,11 @@ const UserSettings = (props: PropsToUserSettings) => {
// Update page to show correct links info in Contextual panel
React.useEffect(() => {
if (props.changeFromPage !== undefined) {
- props.changeFromPage("active-users-settings");
+ if (props.from === "active-users") {
+ props.changeFromPage("active-users-settings");
+ } else if (props.from === "stage-users") {
+ props.changeFromPage("stage-users-settings");
+ }
}
}, [props.changeFromPage]);
diff --git a/src/pages/StageUsers/StageUsersTabs.tsx b/src/pages/StageUsers/StageUsersTabs.tsx
index 539a3755..07bc2f5f 100644
--- a/src/pages/StageUsers/StageUsersTabs.tsx
+++ b/src/pages/StageUsers/StageUsersTabs.tsx
@@ -14,6 +14,7 @@ import UserSettings from "src/components/UsersSections/UserSettings";
import BreadCrumb, { BreadCrumbItem } from "src/components/layouts/BreadCrumb";
import DataSpinner from "src/components/layouts/DataSpinner";
import TitleLayout from "src/components/layouts/TitleLayout";
+import ContextualHelpPanel from "src/components/ContextualHelpPanel/ContextualHelpPanel";
// Hooks
import { useStageUserSettings } from "src/hooks/useUserSettingsData";
// Redux
@@ -55,6 +56,25 @@ const StageUsersTabs = () => {
}
}, [uid]);
+ // Contextual links panel
+ const [fromPageSelected, setFromPageSelected] = React.useState(
+ "stage-users-settings"
+ );
+ const [isContextualPanelExpanded, setIsContextualPanelExpanded] =
+ React.useState(false);
+
+ const changeFromPage = (fromPage: string) => {
+ setFromPageSelected(fromPage);
+ };
+
+ const onOpenContextualPanel = () => {
+ setIsContextualPanelExpanded(!isContextualPanelExpanded);
+ };
+
+ const onCloseContextualPanel = () => {
+ setIsContextualPanelExpanded(false);
+ };
+
// Data loaded from DB
const userSettingsData = useStageUserSettings(uid as string);
@@ -82,53 +102,64 @@ const StageUsersTabs = () => {
return (
<>
-
-
-
-
-
-
+
- Settings}
+
+
+
+
+
-
-
-
-
+ Settings}
+ >
+
+
+
+
+
>
);
};
diff --git a/tests/features/contextual_help_panel.feature b/tests/features/contextual_help_panel.feature
index ccb529b3..a72c112a 100644
--- a/tests/features/contextual_help_panel.feature
+++ b/tests/features/contextual_help_panel.feature
@@ -32,6 +32,16 @@ Feature: Contextual help links panel
When I click on close button in the panel
Then I should not see contextual help panel
+ # - Stage users > Settings page
+ Scenario: Open and close the contextual help links panel on Stage users > Settings page
+ Given I am on "stage-users-settings" page
+ When I click on "Help" button
+ Then I should see contextual help panel
+ And I should see a title "Links" in the panel
+ * I should see a list of links
+ When I click on close button in the panel
+ Then I should not see contextual help panel
+
# Preserved users page
Scenario: Open the contextual help links panel on 'preserved-users' main page
Given I am on "preserved-users" page