From 7151c73aae2e7b1cb155b14738af1da7f820643d Mon Sep 17 00:00:00 2001 From: Viliam Krizan Date: Mon, 21 Aug 2023 15:12:19 +0200 Subject: [PATCH 01/15] fix(pendo): no error on missing pendo --- src/components/ChromeRoute/ChromeRoute.tsx | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/src/components/ChromeRoute/ChromeRoute.tsx b/src/components/ChromeRoute/ChromeRoute.tsx index 1d401ce913..dbc64f6907 100644 --- a/src/components/ChromeRoute/ChromeRoute.tsx +++ b/src/components/ChromeRoute/ChromeRoute.tsx @@ -46,11 +46,13 @@ const ChromeRoute = memo( /** * update pendo metadata on application change */ - try { - window?.pendo?.updateOptions(getPendoConf(user as DeepRequired)); - } catch (error) { - console.error('Unable to update pendo options'); - console.error(error); + if (window.pendo) { + try { + window.pendo.updateOptions(getPendoConf(user as DeepRequired)); + } catch (error) { + console.error('Unable to update pendo options'); + console.error(error); + } } /** From 315eae6718c0db9f56506b1a9bcb2012805682d7 Mon Sep 17 00:00:00 2001 From: Matt Knop Date: Wed, 23 Aug 2023 13:03:05 -0600 Subject: [PATCH 02/15] Adding aliases for new pipeline pr check --- package.json | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/package.json b/package.json index 58a507ad74..63cc8429aa 100644 --- a/package.json +++ b/package.json @@ -30,7 +30,11 @@ "translations:compile": "npx formatjs compile ./locales/translation-template.json --out-file ./src/locales/translations.json", "translations:datafile": "node scripts/createDataJson.js", "verify": "npm-run-all lint build test", - "postinstall": "rm -rf .webpack-cache" + "postinstall": "rm -rf .webpack-cache", + "ci:unit-tests": "run-s test", + "ci:lint": "run-s lint", + "ci:cypress-component-tests": "run-s test:ct", + "ci:cypress-e2e-tests": "run-s test:e2e" }, "repository": { "type": "git", From 768b6ff5d8cf0288371f93b593ec73823d1151c2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Martin=20Maro=C5=A1i?= Date: Mon, 14 Aug 2023 16:09:14 +0200 Subject: [PATCH 03/15] Add dynamic partner title to product selection screen. --- .../Stratosphere/ProductSelection.tsx | 138 +++++++++--------- .../Stratosphere/RedirectBanner.test.tsx | 3 +- .../Stratosphere/RedirectBanner.tsx | 29 +--- src/hooks/useMarketplacePartner.ts | 37 +++++ 4 files changed, 116 insertions(+), 91 deletions(-) create mode 100644 src/hooks/useMarketplacePartner.ts diff --git a/src/components/Stratosphere/ProductSelection.tsx b/src/components/Stratosphere/ProductSelection.tsx index 540aa0e6e5..dfdabf9c26 100644 --- a/src/components/Stratosphere/ProductSelection.tsx +++ b/src/components/Stratosphere/ProductSelection.tsx @@ -14,76 +14,80 @@ import ProductCard from './ProductCard'; import { Header } from '../Header/Header'; import ChromeLink from '../ChromeLink/ChromeLink'; import Footer from './Footer'; +import useMarketplacePartner from '../../hooks/useMarketplacePartner'; import './product-selection.scss'; -const ProductSelection = () => ( -
- -
- - } - > -
- - - - - - - - - - - - - - Congratulations, +const ProductSelection = () => { + const { partner } = useMarketplacePartner(); + return ( + <div id="chrome-app-render-root"> + <Page + header={ + <Masthead className="chr-c-masthead"> + <Header /> + </Masthead> + } + > + <div className="chr-c-product-selection pf-u-pt-lg pf-u-pb-lg"> + <Stack hasGutter> + <StackItem> + <Bullseye> + <Icon size="xl"> + <CheckCircleIcon color="var(--pf-global--success-color--100)" /> + </Icon> + </Bullseye> + </StackItem> + <StackItem> + <Stack> + <StackItem> + <Bullseye> + <Title size="3xl" headingLevel="h1"> + Congratulations, + + + + + + your Red Hat and {partner} accounts are connected and you can now access Red Hat support resources - - - - - your Red Hat and AWS accounts are connected and you can now access Red Hat support resources - - - - - - - - To get started using your Red Hat products, follow the links below - - - - - -
- {productsList.map((item, i) => ( - - ))} -
-
-
- - - - - To manage or learn more about your Red Hat subscriptions, visit{' '} - - subscriptions. - - - - - -
-
-
- -
-); + + + + + + + To get started using your Red Hat products, follow the links below + + + + + +
+ {productsList.map((item, i) => ( + + ))} +
+
+
+ + + + + To manage or learn more about your Red Hat subscriptions, visit{' '} + + subscriptions. + + + + + + + +