File tree Expand file tree Collapse file tree 4 files changed +7
-1
lines changed
docs/getting-started/install Expand file tree Collapse file tree 4 files changed +7
-1
lines changed Original file line number Diff line number Diff line change @@ -15,6 +15,7 @@ import RPMProd from './_snippets/_rpm_install.md'
15
15
import MacOSProd from ' ./_snippets/_macos.md'
16
16
import Docker from ' ./_snippets/_docker.md'
17
17
import {CardPrimary } from ' @clickhouse/click-ui/bundled' ;
18
+ import {galaxyOnClick } from ' @site/src/lib/galaxy/galaxy'
18
19
19
20
# Installation instructions
20
21
@@ -26,7 +27,7 @@ import {CardPrimary} from '@clickhouse/click-ui/bundled';
26
27
infoText = " Get started free"
27
28
infoUrl = " https://auth.clickhouse.cloud/"
28
29
isSelected
29
- onButtonClick = { function Da(){} }
30
+ onButtonClick = { galaxyOnClick ( ' docs.installCloudCallout.buttonClicked ' ) }
30
31
size = " md"
31
32
title = " ClickHouse Cloud"
32
33
topBadgeText = " Recommended"
Original file line number Diff line number Diff line change @@ -86,6 +86,7 @@ export const galaxyOnPage = (prefix, depsArray = []) => {
86
86
galaxyOnFocus ( `${ prefix } .window.focus` , depsArray ) ;
87
87
} ;
88
88
89
+ // Pass String with convention 'namespace.component.eventName'
89
90
export const galaxyOnClick = ( event ) => {
90
91
return ( ) => {
91
92
window . galaxy . track ( event , { interaction : "click" } ) ;
Original file line number Diff line number Diff line change @@ -17,6 +17,7 @@ import IconClose from "@theme/Icon/Close";
17
17
import { useLocation } from "@docusaurus/router" ;
18
18
import useDocusaurusContext from "@docusaurus/useDocusaurusContext" ;
19
19
import RelatedBlogs from "../../../components/RelatedBlogs/RelatedBlogs" ;
20
+ import { galaxyOnClick } from "../../../lib/galaxy/galaxy" ;
20
21
/**
21
22
* Decide if the toc should be rendered, on mobile or desktop viewports
22
23
*/
@@ -90,6 +91,7 @@ export default function DocItemLayout({children}) {
90
91
className = { styles . docCloudClose }
91
92
onClick = { ( ) => {
92
93
setShowPopup ( false )
94
+ galaxyOnClick ( 'docs.translationIssueBanner.buttonClick' )
93
95
window . localStorage . setItem ( 'doc-translate-card-banner' , 'closed' )
94
96
} } >
95
97
< IconClose color = "var(--ifm-color-emphasis-600)" width = { 10 } height = { 10 } />
Original file line number Diff line number Diff line change @@ -6,6 +6,7 @@ import clsx from "clsx";
6
6
import IconClose from '@theme/Icon/Close' ;
7
7
import styles from './styles.module.scss'
8
8
import Feedback from '../../../../components/Feedback' ;
9
+ import { galaxyOnClick } from "../../../../lib/galaxy/galaxy" ;
9
10
10
11
const AD_DATA_ENDPOINT = 'https://cms.clickhouse-dev.com:1337/api/docs-ad'
11
12
@@ -96,6 +97,7 @@ export default function DocItemTOCDesktop() {
96
97
className = { styles . docCloudClose }
97
98
onClick = { ( ) => {
98
99
setClosed ( true )
100
+ galaxyOnClick ( 'docs.sidebarCloudAdvert.buttonClick' )
99
101
window . sessionStorage . setItem ( 'doc-cloud-card-banner' , 'closed' ) ;
100
102
} } >
101
103
< IconClose color = "var(--ifm-color-emphasis-600)" width = { 10 } height = { 10 } />
You can’t perform that action at this time.
0 commit comments