Skip to content

Commit

Permalink
feat(comms): Open customer success zendesk ticket instead email (#25535)
Browse files Browse the repository at this point in the history
  • Loading branch information
MarconLP authored Oct 11, 2024
1 parent 6d0dc46 commit e2eb87e
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 2 deletions.
4 changes: 3 additions & 1 deletion frontend/src/scenes/billing/UnsubscribeCard.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
import { LemonButton, Link } from '@posthog/lemon-ui'
import { useActions } from 'kea'
import { supportLogic } from 'lib/components/Support/supportLogic'
import { UNSUBSCRIBE_SURVEY_ID } from 'lib/constants'

import { BillingProductV2Type } from '~/types'
Expand All @@ -8,6 +9,7 @@ import { billingProductLogic } from './billingProductLogic'

export const UnsubscribeCard = ({ product }: { product: BillingProductV2Type }): JSX.Element => {
const { reportSurveyShown, setSurveyResponse } = useActions(billingProductLogic({ product }))
const { openSupportForm } = useActions(supportLogic)

return (
<div className="p-5 gap-4 flex">
Expand All @@ -26,7 +28,7 @@ export const UnsubscribeCard = ({ product }: { product: BillingProductV2Type }):
reduce your bill
</Link>{' '}
or{' '}
<Link to="mailto:[email protected]?subject=Help%20reducing%20PostHog%20bill" target="_blank">
<Link to="" onClick={() => openSupportForm({ target_area: 'billing', isEmailFormOpen: true })}>
chat with support.
</Link>{' '}
Check out more about our pricing on our{' '}
Expand Down
5 changes: 4 additions & 1 deletion frontend/src/scenes/billing/UnsubscribeSurveyModal.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ import './UnsubscribeSurveyModal.scss'

import { LemonBanner, LemonButton, LemonCheckbox, LemonLabel, LemonModal, LemonTextArea, Link } from '@posthog/lemon-ui'
import { useActions, useValues } from 'kea'
import { supportLogic } from 'lib/components/Support/supportLogic'

import { BillingProductV2AddonType, BillingProductV2Type } from '~/types'

Expand Down Expand Up @@ -32,6 +33,7 @@ export const UnsubscribeSurveyModal = ({
const { deactivateProduct, resetUnsubscribeError } = useActions(billingLogic)
const { unsubscribeError, billingLoading, billing } = useValues(billingLogic)
const { unsubscribeDisabledReason, itemsToDisable } = useValues(exportsUnsubscribeTableLogic)
const { openSupportForm } = useActions(supportLogic)

const textAreaNotEmpty = surveyResponse['$survey_response']?.length > 0
const includesPipelinesAddon =
Expand Down Expand Up @@ -150,10 +152,11 @@ export const UnsubscribeSurveyModal = ({
</Link>
{`${product.type !== 'session_replay' ? ' or ' : ', '}`}
<Link
to="mailto:[email protected]?subject=Help%20reducing%20PostHog%20bill"
to=""
target="_blank"
onClick={() => {
reportSurveyDismissed(surveyID)
openSupportForm({ target_area: 'billing', isEmailFormOpen: true })
}}
>
chat with support
Expand Down

0 comments on commit e2eb87e

Please sign in to comment.