diff --git a/src/authentication/AuthenticationSection.tsx b/src/authentication/AuthenticationSection.tsx index 651e271975..c7e031e620 100644 --- a/src/authentication/AuthenticationSection.tsx +++ b/src/authentication/AuthenticationSection.tsx @@ -32,6 +32,7 @@ import { RequiredActions } from "./RequiredActions"; import { Policies } from "./policies/Policies"; import "./authentication-section.css"; +import helpUrls from "../help-urls"; type UsedBy = "specificClients" | "default" | "specificProviders"; @@ -211,7 +212,12 @@ export default function AuthenticationSection() { }} /> )} - + diff --git a/src/clients/messages.ts b/src/clients/messages.ts index d06ec18a2a..44c7698239 100644 --- a/src/clients/messages.ts +++ b/src/clients/messages.ts @@ -122,7 +122,7 @@ export default { generalSettings: "General Settings", capabilityConfig: "Capability config", clientsExplain: - "Clients are applications and services that can request authentication of a user", + "Clients are applications and services that can request authentication of a user.", explainBearerOnly: "This is a special OIDC type. This client only allows bearer token requests and cannot participate in browser logins.", createSuccess: "Client created successfully", diff --git a/src/components/help-enabler/HelpHeader.tsx b/src/components/help-enabler/HelpHeader.tsx index 2db885664f..b844bd8c22 100644 --- a/src/components/help-enabler/HelpHeader.tsx +++ b/src/components/help-enabler/HelpHeader.tsx @@ -13,6 +13,7 @@ import React, { createContext, FunctionComponent, useState } from "react"; import { useTranslation } from "react-i18next"; import useRequiredContext from "../../utils/useRequiredContext"; import "./help-header.css"; +import helpUrls from "../../help-urls"; type HelpContextProps = { enabled: boolean; @@ -44,7 +45,12 @@ export const HelpHeader = () => { const { t } = useTranslation(); const dropdownItems = [ - + {t("documentation")} diff --git a/src/components/view-header/ViewHeader.tsx b/src/components/view-header/ViewHeader.tsx index a49fcfa448..7dd3797a5d 100644 --- a/src/components/view-header/ViewHeader.tsx +++ b/src/components/view-header/ViewHeader.tsx @@ -22,12 +22,10 @@ import React, { Fragment, } from "react"; import { useTranslation } from "react-i18next"; -import { - FormattedLink, - FormattedLinkProps, -} from "../external-link/FormattedLink"; +import { FormattedLink } from "../external-link/FormattedLink"; import { useHelp } from "../help-enabler/HelpHeader"; import { HelpItem } from "../help-enabler/HelpItem"; +import "../../help-urls"; export type ViewHeaderProps = { titleKey: string; @@ -36,7 +34,7 @@ export type ViewHeaderProps = { isDropdownDisabled?: boolean; subKey?: string | ReactNode; actionsDropdownId?: string; - subKeyLinkProps?: FormattedLinkProps; + helpUrl?: string | undefined; dropdownItems?: ReactElement[]; lowerDropdownItems?: any; lowerDropdownMenuTitle?: any; @@ -59,7 +57,7 @@ export const ViewHeader = ({ badges, isDropdownDisabled, subKey, - subKeyLinkProps, + helpUrl, dropdownItems, lowerDropdownMenuTitle, lowerDropdownItems, @@ -166,9 +164,10 @@ export const ViewHeader = ({ : subKey ? t(subKey as string) : ""} - {subKeyLinkProps && ( + {helpUrl && ( diff --git a/src/events/EventsSection.tsx b/src/events/EventsSection.tsx index 21ebda3f67..4e4839c4b9 100644 --- a/src/events/EventsSection.tsx +++ b/src/events/EventsSection.tsx @@ -43,6 +43,7 @@ import { toRealmSettings } from "../realm-settings/routes/RealmSettings"; import { toUser } from "../user/routes/User"; import { AdminEvents } from "./AdminEvents"; import "./events.css"; +import helpUrls from "../help-urls"; type UserEventSearchForm = { client: string; @@ -413,6 +414,7 @@ export default function EventsSection() { page realm settings to configure. } + helpUrl={helpUrls.eventsUrl} divider={false} /> diff --git a/src/groups/GroupsSection.tsx b/src/groups/GroupsSection.tsx index d5191968a3..8da7ae015d 100644 --- a/src/groups/GroupsSection.tsx +++ b/src/groups/GroupsSection.tsx @@ -28,6 +28,7 @@ import { toGroupsSearch } from "./routes/GroupsSearch"; import { GroupRoleMapping } from "./GroupRoleMapping"; import "./GroupsSection.css"; +import helpUrls from "../help-urls"; export default function GroupsSection() { const { t } = useTranslation("groups"); @@ -107,6 +108,7 @@ export default function GroupsSection() { - + diff --git a/src/realm-settings/RealmSettingsTabs.tsx b/src/realm-settings/RealmSettingsTabs.tsx index 7539ca5bde..d21ea16368 100644 --- a/src/realm-settings/RealmSettingsTabs.tsx +++ b/src/realm-settings/RealmSettingsTabs.tsx @@ -52,6 +52,7 @@ import { UserRegistration } from "./UserRegistration"; import { toDashboard } from "../dashboard/routes/Dashboard"; import environment from "../environment"; import { UserProfileTab } from "./UserProfileTab"; +import helpUrls from "../help-urls"; type RealmSettingsHeaderProps = { onChange: (value: boolean) => void; @@ -118,6 +119,8 @@ const RealmSettingsHeader = ({ /> { return ( @@ -121,6 +122,7 @@ export default function SessionsSection() { dropdownItems={dropdownItems} titleKey="sessions:title" subKey="sessions:sessionExplain" + helpUrl={helpUrls.sessionsUrl} /> {revocationModalOpen && ( diff --git a/src/sessions/messages.ts b/src/sessions/messages.ts index 28357417c5..f5b63c12ef 100644 --- a/src/sessions/messages.ts +++ b/src/sessions/messages.ts @@ -1,7 +1,7 @@ export default { sessions: { title: "Sessions", - sessionExplain: "Some description about sessions", + sessionExplain: "Placeholder for sessions explanation.", searchForSession: "Search session", subject: "Subject", lastAccess: "Last access", diff --git a/src/user-federation/UserFederationSection.tsx b/src/user-federation/UserFederationSection.tsx index e0bf1a54d9..782ad79ccf 100644 --- a/src/user-federation/UserFederationSection.tsx +++ b/src/user-federation/UserFederationSection.tsx @@ -25,6 +25,7 @@ import { ViewHeader } from "../components/view-header/ViewHeader"; import { useAdminClient, useFetch } from "../context/auth/AdminClient"; import { useRealm } from "../context/realm-context/RealmContext"; import "./user-federation.css"; +import helpUrls from "../help-urls"; export default function UserFederationSection() { const [userFederations, setUserFederations] = @@ -69,10 +70,10 @@ export default function UserFederationSection() { , ]; - const learnMoreLinkProps = { - title: t("common:learnMore"), - href: "https://www.keycloak.org/docs/latest/server_admin/index.html#_user-storage-federation", - }; + // const learnMoreLinkProps = { + // title: t("common:learnMore"), + // href: "https://www.keycloak.org/docs/latest/server_admin/index.html#_user-storage-federation", + // }; let cards; @@ -142,8 +143,8 @@ export default function UserFederationSection() { <> 0 ? { lowerDropdownItems: ufAddProviderDropdownItems, diff --git a/src/user-federation/messages.ts b/src/user-federation/messages.ts index 7f9e866796..0ad338cc7b 100644 --- a/src/user-federation/messages.ts +++ b/src/user-federation/messages.ts @@ -3,7 +3,7 @@ export default { userFederation: "User federation", descriptionLanding: "This is the description for the user federation landing page", - userFederationExplanation: + userFederationExplain: "Keycloak can federate external user databases. Out of the box we have support for LDAP and Active Directory.", getStarted: "To get started, select a provider from the list below.", providers: "Add providers", diff --git a/src/user/UsersSection.tsx b/src/user/UsersSection.tsx index f8b92d8c3e..bae4e89c07 100644 --- a/src/user/UsersSection.tsx +++ b/src/user/UsersSection.tsx @@ -41,6 +41,7 @@ import { toUser } from "./routes/User"; import { toAddUser } from "./routes/AddUser"; import "./user-section.css"; +import helpUrls from "../help-urls"; type BruteUser = UserRepresentation & { brute?: Record; @@ -260,7 +261,11 @@ export default function UsersSection() { <> - +