mirror of
https://github.com/overleaf/overleaf.git
synced 2024-12-03 22:27:55 -05:00
8472ac6fc6
* Add Upgrade buttons on project dash and editor header GitOrigin-RevId: 16325ffb2e63beeaff914e0b95db3faddcdf241a
24 lines
611 B
JavaScript
24 lines
611 B
JavaScript
import { useTranslation } from 'react-i18next'
|
|
import * as eventTracking from '../../../infrastructure/event-tracking'
|
|
|
|
function UpgradePrompt() {
|
|
const { t } = useTranslation()
|
|
|
|
function handleClick(e) {
|
|
eventTracking.send('subscription-funnel', 'code-editor', 'upgrade')
|
|
eventTracking.sendMB('upgrade-button-click', { source: 'code-editor' })
|
|
}
|
|
|
|
return (
|
|
<a
|
|
className="toolbar-header-upgrade-prompt btn btn-primary btn-xs"
|
|
href="/user/subscription/plans"
|
|
target="_blank"
|
|
onClick={handleClick}
|
|
>
|
|
{t('upgrade')}
|
|
</a>
|
|
)
|
|
}
|
|
|
|
export default UpgradePrompt
|