Improve pricing visibility

pull/1/head
yflory 5 years ago
parent 74372ba5d4
commit c95db33157

@ -26,7 +26,8 @@ var getLanguage = messages._getLanguage = function () {
var l = getBrowserLanguage();
// Edge returns 'fr-FR' --> transform it to 'fr' and check again
return map[l] ? l :
(map[l.split('-')[0]] ? l.split('-')[0] : 'en');
(map[l.split('-')[0]] ? l.split('-')[0] :
(map[l.split('_')[0]] ? l.split('_')[0] : 'en'));
};
var language = getLanguage();

@ -146,7 +146,7 @@ define([
//h('a.nav-item.nav-link', { href: '/what-is-cryptpad.html'}, Msg.topbar_whatIsCryptpad), // Moved the FAQ
//h('a.nav-item.nav-link', { href: '/faq.html'}, Msg.faq_link),
h('a.nav-item.nav-link', { href: 'https://blog.cryptpad.fr/'}, Msg.blog),
h('a.nav-item.nav-link', { href: '/features.html'}, Msg.features),
h('a.nav-item.nav-link', { href: '/features.html'}, Msg.pricing),
h('a.nav-item.nav-link', { href: '/privacy.html'}, Msg.privacy),
//h('a.nav-item.nav-link', { href: '/contact.html'}, Msg.contact),
//h('a.nav-item.nav-link', { href: '/about.html'}, Msg.about),

@ -21,14 +21,17 @@ define([
target: '_blank',
rel: 'noopener noreferrer'
}, h('button.cp-features-register-button', Msg.features_f_subscribe));
$(premiumButton).click(function (e) {
/*$(premiumButton).click(function (e) {
if (LocalStore.isLoggedIn()) { return; }
// Not logged in: go to /login with a redirect to this page
e.preventDefault();
e.stopPropagation();
sessionStorage.redirectTo = '/features.html';
window.location.href = '/login/';
});
});*/
Msg.features_emailRequired = 'Email address required';
Msg.features_noData = 'No personal data required';
Msg.features_pricing = '{0}, {1} or {2}€/month';
return h('div#cp-main', [
Pages.infopageTopbar(),
h('div.container-fluid.cp_cont_features',[
@ -43,6 +46,10 @@ define([
h('div.card-body',[
h('h3.text-center',Msg.features_anon)
]),
h('div.card-body.cp-pricing',[
h('div.text-center', '0€'),
h('div.text-center', Msg.features_noData),
]),
h('ul.list-group.list-group-flush',
['apps', 'core', 'file0', 'cryptdrive0', 'storage0'].map(function (f) {
return h('li.list-group-item', [
@ -61,6 +68,10 @@ define([
h('div.card-body',[
h('h3.text-center',Msg.features_registered)
]),
h('div.card-body.cp-pricing',[
h('div.text-center', '0€'),
h('div.text-center', Msg.features_noData),
]),
h('ul.list-group.list-group-flush', [
['anon', 'social', 'file1', 'cryptdrive1', 'devices', 'storage1'].map(function (f) {
return h('li.list-group-item', [
@ -87,6 +98,13 @@ define([
h('div.card-body',[
h('h3.text-center',Msg.features_premium)
]),
h('div.card-body.cp-pricing',[
h('div.text-center', h('a', {
href: accounts.upgradeURL,
target: '_blank'
}, Msg._getKey('features_pricing', ['5', '10', '15']))),
h('div.text-center', Msg.features_emailRequired),
]),
h('ul.list-group.list-group-flush', [
['reg', 'storage2', 'support', 'supporter'].map(function (f) {
return h('li.list-group-item', [

@ -47,6 +47,12 @@
h3 {
margin: 0;
}
&.cp-pricing {
div {
font-size: 1.2em;
color: @cryptpad_color_blue;
}
}
}
}
h3 {

@ -1859,6 +1859,15 @@ define([
content: $userAdminContent.html()
});
}
options.push({
tag: 'a',
attributes: {
'target': '_blank',
'href': origin+'/index.html',
'class': 'fa fa-home'
},
content: h('span', Messages.homePage)
});
if (padType !== 'drive' || (!accountName && priv.newSharedFolder)) {
options.push({
tag: 'a',
@ -1870,6 +1879,7 @@ define([
content: h('span', Messages.login_accessDrive)
});
}
options.push({ tag: 'hr' });
// Add the change display name button if not in read only mode
if (config.changeNameButtonCls && config.displayChangeName && !AppConfig.disableProfile) {
options.push({
@ -1892,6 +1902,7 @@ define([
content: h('span', Messages.settingsButton)
});
}
options.push({ tag: 'hr' });
// Add administration panel link if the user is an admin
if (priv.edPublic && Array.isArray(Config.adminKeys) && Config.adminKeys.indexOf(priv.edPublic) !== -1) {
options.push({
@ -1907,6 +1918,16 @@ define([
content: h('span', Messages.supportPage || 'Support')
});
}
options.push({
tag: 'a',
attributes: {
'target': '_blank',
'href': origin+'/features.html',
'class': 'fa fa-star-o'
},
content: h('span', priv.plan ? Messages.settings_cat_subscription : Messages.pricing)
});
options.push({ tag: 'hr' });
// Add login or logout button depending on the current status
if (accountName) {
options.push({

Loading…
Cancel
Save