Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

🎨 Added option to change the name of the free tier #19715

Merged
merged 1 commit into from
Feb 20, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -59,10 +59,6 @@ const features = [{
title: 'New email addresses',
description: 'For self hosters, forces the usage of the mail.from config as from address for all outgoing emails',
flag: 'newEmailAddresses'
},{
title: 'Portal improvements',
description: 'Adds a bunch of improvements to portal and portal settings',
flag: 'portalImprovements'
}];

const AlphaFeatures: React.FC = () => {
Expand Down
10 changes: 4 additions & 6 deletions apps/portal/src/utils/helpers.js
Original file line number Diff line number Diff line change
Expand Up @@ -431,7 +431,8 @@ export function getSiteProducts({site, pageQuery}) {
}
if (hasFreeProductPrice({site})) {
products.unshift({
id: 'free'
id: 'free',
type: 'free'
});
}
return products;
Expand All @@ -450,11 +451,8 @@ export function getFreeProductBenefits({site}) {
}

export function getFreeTierTitle({site}) {
if (hasOnlyFreeProduct({site})) {
return 'Free membership';
} else {
return 'Free';
}
const freeProduct = getFreeProduct({site});
return freeProduct?.name || 'Free';
}

export function getFreeTierDescription({site}) {
Expand Down
6 changes: 3 additions & 3 deletions ghost/core/core/shared/labs.js
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,8 @@ const GA_FEATURES = [
'recommendations',
'listUnsubscribeHeader',
'filterEmailDisabled',
'newEmailAddresses'
'newEmailAddresses',
'portalImprovements'
];

// NOTE: this allowlist is meant to be used to filter out any unexpected
Expand All @@ -47,8 +48,7 @@ const ALPHA_FEATURES = [
'lexicalIndicators',
// 'adminXOffers',
'filterEmailDisabled',
'adminXDemo',
'portalImprovements'
'adminXDemo'
];

module.exports.GA_KEYS = [...GA_FEATURES];
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1155,7 +1155,7 @@ exports[`Settings API Edit Can edit a setting 2: [headers] 1`] = `
Object {
"access-control-allow-origin": "http://127.0.0.1:2369",
"cache-control": "no-cache, private, no-store, must-revalidate, max-stale=0, post-check=0, pre-check=0",
"content-length": "4534",
"content-length": "4562",
"content-type": "application/json; charset=utf-8",
"content-version": StringMatching /v\\\\d\\+\\\\\\.\\\\d\\+/,
"etag": StringMatching /\\(\\?:W\\\\/\\)\\?"\\(\\?:\\[ !#-\\\\x7E\\\\x80-\\\\xFF\\]\\*\\|\\\\r\\\\n\\[\\\\t \\]\\|\\\\\\\\\\.\\)\\*"/,
Expand Down
Loading