Merge pull request #8240 from overleaf/tm-teardown-persistent-upgrade-test

Teardown persistent upgrade prompt split test and fix styling

GitOrigin-RevId: 8776231c3308c5f08b91232c962c9796a5f4afa0
This commit is contained in:
Thomas
2022-06-02 08:02:45 +00:00
committed by Copybot
parent df35a67707
commit 5e2933e2fe
5 changed files with 67 additions and 168 deletions
@@ -4,24 +4,9 @@ export default App.controller(
'LeftHandMenuPromoController',
function ($scope, UserAffiliationsDataService, eventTracking) {
$scope.hasProjects = window.data.projects.length > 0
$scope.userHasNoSubscription = window.userHasNoSubscription
$scope.upgradeSubscription = function () {
eventTracking.send('subscription-funnel', 'project-page', 'upgrade')
eventTracking.sendMB('upgrade-button-click', {
source: 'dashboard',
})
}
$scope.share = function () {
eventTracking.send('subscription-funnel', 'project-page', 'sharing')
}
const _userHasNoAffiliation = function () {
$scope.withAffiliations = window.data.userAffiliations.length > 0
$scope.userOnPayingUniversity = window.data.userAffiliations.some(
affiliation => affiliation.licence && affiliation.licence !== 'free'
)
}
_userHasNoAffiliation()
@@ -198,6 +198,7 @@
}
.toolbar-header-upgrade-prompt {
margin-left: 10px;
@media (max-width: @screen-md-min) {
display: none;
}