From cc6cbe208645d6fe148f4d1876ef40273d99d505 Mon Sep 17 00:00:00 2001 From: Jay <159848059+jayacryl@users.noreply.github.com> Date: Wed, 18 Sep 2024 17:59:46 -0400 Subject: [PATCH] feat(docs-site) tours to open in a modal (#11420) --- .../CaseStudy/case-study.module.scss | 4 +- .../src/pages/_components/Community/index.js | 3 +- .../pages/_components/Hero/hero.module.scss | 3 +- .../src/pages/_components/Hero/index.js | 9 ++-- .../src/pages/_components/Trial/index.js | 7 ++- .../pages/_components/Trial/trial.module.scss | 2 +- .../src/pages/cloud/UnifiedTabs/index.js | 2 +- docs-website/src/pages/index.js | 22 +++++++-- docs-website/src/styles/global.scss | 47 +++++++++++++++++++ 9 files changed, 83 insertions(+), 16 deletions(-) diff --git a/docs-website/src/pages/_components/CaseStudy/case-study.module.scss b/docs-website/src/pages/_components/CaseStudy/case-study.module.scss index a90788b9c2047..e17f1f74656dc 100644 --- a/docs-website/src/pages/_components/CaseStudy/case-study.module.scss +++ b/docs-website/src/pages/_components/CaseStudy/case-study.module.scss @@ -167,14 +167,14 @@ font-family: "Manrope"; div { - width: 70%; + width: 80%; margin: auto; font-size: 2rem; line-height: normal; font-weight: 400; } p { - width: 60%; + width: 80%; margin: auto; font-size: 1.1rem; line-height: 1.5rem; diff --git a/docs-website/src/pages/_components/Community/index.js b/docs-website/src/pages/_components/Community/index.js index 2ef6eba45092c..a4f2b2304e51e 100644 --- a/docs-website/src/pages/_components/Community/index.js +++ b/docs-website/src/pages/_components/Community/index.js @@ -74,8 +74,7 @@ const Community = () => {

- Q&A. Office Hours.  Monthly Town Hall.  Job - Postings. + Q&A.  Office Hours.  Think Tanks.  Job Postings.

Join Slack diff --git a/docs-website/src/pages/_components/Hero/hero.module.scss b/docs-website/src/pages/_components/Hero/hero.module.scss index 9e3fa5a1c516c..2484b259a32c2 100644 --- a/docs-website/src/pages/_components/Hero/hero.module.scss +++ b/docs-website/src/pages/_components/Hero/hero.module.scss @@ -83,7 +83,7 @@ margin-left: 4px; height: 1.8rem; padding-left: 2px; - padding-right: 8px; + padding-right: 6px; font-family: 'Manrope'; font-style: normal; font-weight: 400; @@ -213,6 +213,7 @@ font-size: .8rem; height: 1.2rem; padding-left: 0px; + padding-right: 4px; } } .hero__cta { diff --git a/docs-website/src/pages/_components/Hero/index.js b/docs-website/src/pages/_components/Hero/index.js index daae86c8094e7..2369c4668bfcd 100644 --- a/docs-website/src/pages/_components/Hero/index.js +++ b/docs-website/src/pages/_components/Hero/index.js @@ -24,7 +24,7 @@ import { animate, motion, useMotionValue, useTransform } from "framer-motion"; const SOLUTION_TEXTS = ["AI Governance", "Data Discovery", "AI Collaboration", "Data Governance", "Data Democratization", "Data Observability"]; -const Hero = ({}) => { +const Hero = ({ onOpenTourModal }) => { // const { colorMode } = useColorMode(); const textIndex = useMotionValue(0); const baseText = useTransform(textIndex, (latest) => SOLUTION_TEXTS[latest] || ""); @@ -71,12 +71,13 @@ const Hero = ({}) => { Book a Demo - Product Tour - + Get started with Core → diff --git a/docs-website/src/pages/_components/Trial/index.js b/docs-website/src/pages/_components/Trial/index.js index 5c0ac992d1366..0f707993c55b7 100644 --- a/docs-website/src/pages/_components/Trial/index.js +++ b/docs-website/src/pages/_components/Trial/index.js @@ -3,7 +3,7 @@ import styles from "./trial.module.scss"; import useBaseUrl from "@docusaurus/useBaseUrl"; import Link from "@docusaurus/Link"; -const Trial = () => { +const Trial = ({onOpenTourModal}) => { return (
@@ -15,7 +15,10 @@ const Trial = () => {

Book a Demo - Product Tour + Product Tour
Get started with Core →
diff --git a/docs-website/src/pages/_components/Trial/trial.module.scss b/docs-website/src/pages/_components/Trial/trial.module.scss index 64d92c9abe08c..f774bfffa3f7a 100644 --- a/docs-website/src/pages/_components/Trial/trial.module.scss +++ b/docs-website/src/pages/_components/Trial/trial.module.scss @@ -191,7 +191,7 @@ flex-direction: column; width: 90vw; min-width: 0; - margin: 2rem auto; + margin: 4rem auto; } .trial { flex-direction: column; diff --git a/docs-website/src/pages/cloud/UnifiedTabs/index.js b/docs-website/src/pages/cloud/UnifiedTabs/index.js index 7ae348885bca2..c0fbc25a8de6b 100644 --- a/docs-website/src/pages/cloud/UnifiedTabs/index.js +++ b/docs-website/src/pages/cloud/UnifiedTabs/index.js @@ -56,7 +56,7 @@ const TabbedComponent = () => { {activeTab === index && (
-
)} diff --git a/docs-website/src/pages/index.js b/docs-website/src/pages/index.js index f79875f423d47..d538831ca3dca 100644 --- a/docs-website/src/pages/index.js +++ b/docs-website/src/pages/index.js @@ -1,4 +1,4 @@ -import React from "react"; +import React, { useState } from "react"; import Layout from "@theme/Layout"; import Link from "@docusaurus/Link"; import useDocusaurusContext from "@docusaurus/useDocusaurusContext"; @@ -17,6 +17,7 @@ import Community from "./_components/Community"; import SocialMedia from "./_components/SocialMedia"; import CaseStudy from "./_components/CaseStudy"; import Trial from "./_components/Trial"; +import CloseButton from "@ant-design/icons/CloseCircleFilled"; const companyIndexes = require("../../adoptionStoriesIndexes.json"); const companies = companyIndexes.companies; @@ -33,12 +34,27 @@ function Home() { window.location.replace("/docs"); } + const [isTourModalVisible, setIsTourModalVisible] = useState(false); + const onOpenTourModal = () => { + setIsTourModalVisible(true); + }; + const onCloseTourModal = () => { + setIsTourModalVisible(false); + }; return !siteConfig.customFields.isSaas ? ( - + {isTourModalVisible ? ( +
+
+ +
+