From 95f361ab4429ce07b6ea8cbe1ec38f52fadd4ec4 Mon Sep 17 00:00:00 2001 From: Hyejin Yoon <0327jane@gmail.com> Date: Mon, 4 Nov 2024 17:18:58 +0900 Subject: [PATCH 01/13] fix: install servicebell & add condition for markprompt (#11532) --- docs-website/package.json | 1 + docs-website/src/pages/cloud/index.js | 9 ++++++++- docs-website/src/theme/Footer/index.js | 6 +++++- docs-website/yarn.lock | 5 +++++ 4 files changed, 19 insertions(+), 2 deletions(-) diff --git a/docs-website/package.json b/docs-website/package.json index e1130148864e5..8c65b259f337d 100644 --- a/docs-website/package.json +++ b/docs-website/package.json @@ -35,6 +35,7 @@ "@octokit/plugin-throttling": "^3.5.1", "@octokit/rest": "^18.6.2", "@radix-ui/react-visually-hidden": "^1.0.2", + "@servicebell/widget": "^0.1.6", "@supabase/supabase-js": "^2.33.1", "@swc/core": "^1.4.2", "antd": "^5.0.7", diff --git a/docs-website/src/pages/cloud/index.js b/docs-website/src/pages/cloud/index.js index 6e126adc4cb3a..377fe0aa6475e 100644 --- a/docs-website/src/pages/cloud/index.js +++ b/docs-website/src/pages/cloud/index.js @@ -1,4 +1,4 @@ -import React, { useState } from "react"; +import React, { useEffect, useState } from "react"; import Layout from "@theme/Layout"; import Link from "@docusaurus/Link"; import useDocusaurusContext from "@docusaurus/useDocusaurusContext"; @@ -10,8 +10,11 @@ import UnifiedTabs from "./UnifiedTabs"; import FeatureCards from "./FeatureCards"; import Hero from "./Hero"; import DemoForm from "./DemoForm"; +import ServiceBell from "@servicebell/widget"; import DemoFormModal from "./DemoFormModal"; +const SERVICE_BELL_ID = "00892146e5bc46d98d55ecc2b2fa67e2"; + function Home() { const context = useDocusaurusContext(); const { siteConfig = {} } = context; @@ -24,6 +27,10 @@ function Home() { window.location.replace("/docs"); } + useEffect(() => { + ServiceBell("init", SERVICE_BELL_ID, { hidden: false }); + }, []); + return !siteConfig.customFields.isSaas ? ( - + {isDocsPage && }