From a72ce851f1048e29c8b652eb800f7442c5dbc7d1 Mon Sep 17 00:00:00 2001 From: Candy Tsai Date: Wed, 15 Jan 2025 18:55:37 +0800 Subject: [PATCH] Add support doc links to account restored banner --- .../components/inline-support-link/context-links.js | 8 ++++++++ .../use-restore-sites-reminder-banner.tsx | 13 ++++++++++++- 2 files changed, 20 insertions(+), 1 deletion(-) diff --git a/client/components/inline-support-link/context-links.js b/client/components/inline-support-link/context-links.js index 4e7c89eb1408e2..7b511cb3524814 100644 --- a/client/components/inline-support-link/context-links.js +++ b/client/components/inline-support-link/context-links.js @@ -179,6 +179,10 @@ const contextLinks = { link: 'https://wordpress.com/support/user-roles/#adding-users-to-your-site', post_id: 1221, }, + 'invite-people': { + link: 'https://wordpress.com/support/invite-people/', + post_id: 1221, + }, 'manage-profile': { link: 'https://wordpress.com/support/manage-my-profile/', post_id: 19775, @@ -279,6 +283,10 @@ const contextLinks = { link: 'https://wordpress.com/support/manage-purchases/', post_id: 111349, }, + 'restore-site': { + link: 'https://wordpress.com/support/delete-site/#restore-a-deleted-site', + post_id: 14411, + }, 'reusable-blocks': { link: 'https://wordpress.com/support/wordpress-editor/blocks/reusable-block/', post_id: 157539, diff --git a/client/sites/components/sites-dashboard-banners/use-restore-sites-reminder-banner.tsx b/client/sites/components/sites-dashboard-banners/use-restore-sites-reminder-banner.tsx index 7ac292116eb605..65436ae24154d8 100644 --- a/client/sites/components/sites-dashboard-banners/use-restore-sites-reminder-banner.tsx +++ b/client/sites/components/sites-dashboard-banners/use-restore-sites-reminder-banner.tsx @@ -1,6 +1,7 @@ import { NoticeBanner } from '@automattic/components'; import { translate } from 'i18n-calypso'; import { useState } from 'react'; +import InlineSupportLink from 'calypso/components/inline-support-link'; import { recordTracksEvent } from 'calypso/state/analytics/actions'; import './styles.scss'; @@ -35,7 +36,17 @@ export function useRestoreSitesBanner() { >
{ translate( - 'You’ll need to invite any users that previously had access to your sites.' + `{{restoreSiteLink}}Restore sites{{/restoreSiteLink}} from the action menu. You'll also need to {{invitePeopleLink}}invite any users{{/invitePeopleLink}} that previously had access to your sites.`, + { + components: { + restoreSiteLink: ( + + ), + invitePeopleLink: ( + + ), + }, + } ) }