diff --git a/services/web/frontend/extracted-translations.json b/services/web/frontend/extracted-translations.json index a955fd4bef..157e8f4a70 100644 --- a/services/web/frontend/extracted-translations.json +++ b/services/web/frontend/extracted-translations.json @@ -335,6 +335,7 @@ "comment_only_upgrade_for_track_changes": "", "comment_only_upgrade_to_enable_track_changes": "", "common": "", + "commons": "", "commons_plan_tooltip": "", "compact": "", "company_name": "", @@ -1486,7 +1487,6 @@ "proceeding_to_paypal_takes_you_to_the_paypal_site_to_pay": "", "processing": "", "processing_uppercase": "", - "professional": "", "progress_bar_percentage": "", "project_access": "", "project_actions": "", diff --git a/services/web/frontend/js/features/project-list/components/current-plan-widget/commons-plan.tsx b/services/web/frontend/js/features/project-list/components/current-plan-widget/commons-plan.tsx index d62a051527..94a89c646c 100644 --- a/services/web/frontend/js/features/project-list/components/current-plan-widget/commons-plan.tsx +++ b/services/web/frontend/js/features/project-list/components/current-plan-widget/commons-plan.tsx @@ -5,14 +5,10 @@ import MaterialIcon from '@/shared/components/material-icon' type CommonsPlanProps = Pick< CommonsPlanSubscription, - 'subscription' | 'plan' | 'featuresPageURL' + 'subscription' | 'featuresPageURL' > -function CommonsPlan({ - featuresPageURL, - subscription, - plan, -}: CommonsPlanProps) { +function CommonsPlan({ featuresPageURL, subscription }: CommonsPlanProps) { const { t } = useTranslation() const currentPlanLabel = ( {currentPlanLabel} ) diff --git a/services/web/frontend/js/features/settings/components/emails/email.tsx b/services/web/frontend/js/features/settings/components/emails/email.tsx index b5ef0b87dd..b62759e0d5 100644 --- a/services/web/frontend/js/features/settings/components/emails/email.tsx +++ b/services/web/frontend/js/features/settings/components/emails/email.tsx @@ -21,11 +21,11 @@ function Email({ userEmailData }: EmailProps) { ) const isPrimary = userEmailData.default - const isProfessional = + const hasInstitutionalSubscription = userEmailData.confirmedAt && userEmailData.affiliation?.institution.confirmed && userEmailData.affiliation.licence !== 'free' - const hasBadges = isPrimary || isProfessional + const hasBadges = isPrimary || hasInstitutionalSubscription return ( <> @@ -52,8 +52,8 @@ function Email({ userEmailData }: EmailProps) { Primary{' '} )} - {isProfessional && ( - {t('professional')} + {hasInstitutionalSubscription && ( + {t('commons')} )} )} diff --git a/services/web/frontend/js/features/settings/components/emails/sso-alert.tsx b/services/web/frontend/js/features/settings/components/emails/sso-alert.tsx index c4d7f23506..2ee535281b 100644 --- a/services/web/frontend/js/features/settings/components/emails/sso-alert.tsx +++ b/services/web/frontend/js/features/settings/components/emails/sso-alert.tsx @@ -72,7 +72,7 @@ export function SSOAlert() { ]} // eslint-disable-line react/jsx-key - values={{ featureType: t('professional') }} + values={{ featureType: t('commons') }} shouldUnescape tOptions={{ interpolation: { escapeValue: true } }} /> diff --git a/services/web/frontend/js/features/subscription/components/dashboard/institution-memberships.tsx b/services/web/frontend/js/features/subscription/components/dashboard/institution-memberships.tsx index ef508b9173..18fb768da7 100644 --- a/services/web/frontend/js/features/subscription/components/dashboard/institution-memberships.tsx +++ b/services/web/frontend/js/features/subscription/components/dashboard/institution-memberships.tsx @@ -32,7 +32,7 @@ function InstitutionMemberships() { 0) { - planName = 'Overleaf Pro' + planName = 'Overleaf Commons' } if (memberGroupSubscriptions.length > 0) { if (memberGroupSubscriptions.some(s => s.planLevelName === 'Pro')) { diff --git a/services/web/locales/da.json b/services/web/locales/da.json index 756c970dc6..0267e901d8 100644 --- a/services/web/locales/da.json +++ b/services/web/locales/da.json @@ -275,7 +275,7 @@ "column_width_is_x_click_to_resize": "Kolonnebredden er __width__. Klik for at ændre", "comment": "Kommentar", "common": "Almindelig", - "commons_plan_tooltip": "Du er på __plan__ abonnementet gennem din tilknytning til __institution__. Klik for at finde ud af hvordan du bedst udnytter dine Overlaf Premium-funktioner.", + "commons_plan_tooltip": "Du er på Commons abonnementet gennem din tilknytning til __institution__. Klik for at finde ud af hvordan du bedst udnytter dine Overlaf Premium-funktioner.", "compact": "Kompakt", "company_name": "Virksomhedsnavn", "compare": "Sammenlign", @@ -849,7 +849,7 @@ "institution_acct_successfully_linked_2": "Din <0>__appName__-konto er nu sammenkædet med din institutionelle konto fra <0>__institutionName__.", "institution_and_role": "Institution og rolle", "institution_email_new_to_app": "Din __institutionName__ e-mailaddresse (__email__) er ny for __appName__.", - "institution_has_overleaf_subscription": "<0>__institutionName__ har et Overleaf abonnement. Klik på bekræftelseslinket sendt til __emailAddress__ for at opgradere til <0>Overleaf Professionel.", + "institution_has_overleaf_subscription": "<0>__institutionName__ har et Overleaf abonnement. Klik på bekræftelseslinket sendt til __emailAddress__ for at opgradere til <0>Overleaf Commons.", "institution_templates": "Institutionsskabeloner", "institutional": "Institutionel", "institutional_login_unknown": "Beklager, vi ved ikke hvilken institution har udstedt den e-mailadresse. Du kan kigge i vores liste over institutioner for at finde den, eller du kan gøre brug af en af de andre muligheder herunder.", diff --git a/services/web/locales/de.json b/services/web/locales/de.json index 2fc9d9a275..7f22db0ee6 100644 --- a/services/web/locales/de.json +++ b/services/web/locales/de.json @@ -335,7 +335,7 @@ "comment": "Kommentar", "comment_only": "Nur Kommentare", "common": "Häufige", - "commons_plan_tooltip": "Du hast Zugriff auf ein __plan__ Abonnement über deine Angehörigkeit bei __institution__. Klicke hier um herauszufinden was die Overleaf Premiumfunktionen Dir ermöglichen.", + "commons_plan_tooltip": "Du hast Zugriff auf ein Commons Abonnement über deine Angehörigkeit bei __institution__. Klicke hier um herauszufinden was die Overleaf Premiumfunktionen Dir ermöglichen.", "compact": "Kompakt", "company_name": "Firmenname", "compare": "Vergleichen", @@ -790,7 +790,7 @@ "institution_acct_successfully_linked_2": "Dein Konto <0>__appName__ wurde erfolgreich mit deinem institutionellen Konto <0>__institutionName__ verknüpft.", "institution_and_role": "Institution und Rolle", "institution_email_new_to_app": "Deine __institutionName__-E-Mail-Adresse (__email__) ist neu bei __appName__.", - "institution_has_overleaf_subscription": "<0>__institutionName__ hat ein Overleaf-Abonnement. Klicke auf den Bestätigungslink, der an __emailAddress__ gesendet wurde, um auf <0>Overleaf Professional umzusteigen.", + "institution_has_overleaf_subscription": "<0>__institutionName__ hat ein Overleaf-Abonnement. Klicke auf den Bestätigungslink, der an __emailAddress__ gesendet wurde, um auf <0>Overleaf Commons umzusteigen.", "institution_templates": "Institutionsvorlagen", "institutional": "Institutionell", "institutional_login_unknown": "Leider wissen wir nicht, welche Institution diese E-Mail-Adresse ausgegeben hat. Du kannst unsere Liste der Institutionen durchsuchen, um deine zu finden, oder du kannst eine der anderen Optionen nutzen.", diff --git a/services/web/locales/en.json b/services/web/locales/en.json index afcb94e09e..0b2171164d 100644 --- a/services/web/locales/en.json +++ b/services/web/locales/en.json @@ -439,7 +439,8 @@ "comment_only_upgrade_for_track_changes": "Comment only. Upgrade for track changes.", "comment_only_upgrade_to_enable_track_changes": "Comment only. <0>Upgrade to enable track changes.", "common": "Common", - "commons_plan_tooltip": "You’re on the __plan__ plan because of your affiliation with __institution__. Click to find out how to make the most of your Overleaf premium features.", + "commons": "Commons", + "commons_plan_tooltip": "You’re on the Commons plan provided by __institution__. Click to find out how to make the most of your Overleaf premium features.", "community_articles": "Community articles", "community_articles_lowercase": "community articles", "compact": "Compact", @@ -1259,7 +1260,7 @@ "institution_acct_successfully_linked_2": "Your <0>__appName__ account was successfully linked to your <0>__institutionName__ institutional account.", "institution_and_role": "Institution and role", "institution_email_new_to_app": "Your __institutionName__ email (__email__) is new to __appName__.", - "institution_has_overleaf_subscription": "<0>__institutionName__ has an Overleaf subscription. Click the confirmation link sent to __emailAddress__ to upgrade to <0>Overleaf Pro.", + "institution_has_overleaf_subscription": "<0>__institutionName__ has an Overleaf subscription. Click the confirmation link sent to __emailAddress__ to upgrade to <0>Overleaf Commons.", "institution_templates": "Institution Templates", "institutional": "Institutional", "institutional_login_unknown": "Sorry, we don’t know which institution issued that email address. You can browse our list of institutions to find yours, or you can use one of the other options below.", diff --git a/services/web/locales/fr.json b/services/web/locales/fr.json index ea0fa023e1..078280989e 100644 --- a/services/web/locales/fr.json +++ b/services/web/locales/fr.json @@ -228,7 +228,7 @@ "column_width_is_x_click_to_resize": "La largeur de la colonne est __width__. Cliquez pour redimensionner", "comment": "Commentaire", "common": "Commun", - "commons_plan_tooltip": "Vous bénéficiez de l’offre __plan__ en raison de votre affiliation avec __institution__. Cliquez pour découvrir comment profiter au mieux de vos fonctionnalités Overleaf premium.", + "commons_plan_tooltip": "Vous bénéficiez de l’offre Commons en raison de votre affiliation avec __institution__. Cliquez pour découvrir comment profiter au mieux de vos fonctionnalités Overleaf premium.", "compact": "Compact", "company_name": "Nom de l’entreprise", "comparing_from_x_to_y": "Différence entre <0>__startTime__ et <0>__endTime__", diff --git a/services/web/locales/zh-CN.json b/services/web/locales/zh-CN.json index 3634aa44f5..1613cacfea 100644 --- a/services/web/locales/zh-CN.json +++ b/services/web/locales/zh-CN.json @@ -322,7 +322,7 @@ "comment_only_upgrade_for_track_changes": "仅评论。升级可跟踪更改。", "comment_only_upgrade_to_enable_track_changes": "仅评论。<0>升级以启用跟踪更改。", "common": "通用", - "commons_plan_tooltip": "由于您与 __institution__ 的隶属关系,您加入了 __plan__ 计划。 单击以了解如何充分利用 Overleaf 高级功能。", + "commons_plan_tooltip": "由于您与 __institution__ 的隶属关系,您加入了 Commons 计划。 单击以了解如何充分利用 Overleaf 高级功能。", "community_articles": "社区文章", "community_articles_lowercase": "社区文章", "compact": "紧凑的", @@ -981,7 +981,7 @@ "institution_acct_successfully_linked_2": "您的<0>__appName__帐户已成功链接到您的<0\\>__institutionName__机构帐户。", "institution_and_role": "机构和角色", "institution_email_new_to_app": "您的 __institutionName__ 电子邮件地址 (__email__) 对__appName__ 是新的。", - "institution_has_overleaf_subscription": "<0>__institutionName__已有Overleaf订阅。单击发送到__emailAddress__的确认链接,升级到<0>Overleaf Professional。", + "institution_has_overleaf_subscription": "<0>__institutionName__已有Overleaf订阅。单击发送到__emailAddress__的确认链接,升级到<0>Overleaf Commons。", "institution_templates": "机构模版", "institutional": "机构", "institutional_login_unknown": "抱歉,我们不知道是哪个机构发的那个电子邮件地址。您可以浏览我们的\n机构列表 找到您的机构,也可以在此处使用您的电子邮件地址和密码注册。", diff --git a/services/web/test/frontend/features/project-list/components/current-plan-widget.test.tsx b/services/web/test/frontend/features/project-list/components/current-plan-widget.test.tsx index 4ad1bc7443..edfe1b4864 100644 --- a/services/web/test/frontend/features/project-list/components/current-plan-widget.test.tsx +++ b/services/web/test/frontend/features/project-list/components/current-plan-widget.test.tsx @@ -289,7 +289,7 @@ describe('', function () { await screen.findByRole('tooltip', { name: new RegExp( - `on the ${subscription.plan.name} plan because of your affiliation with ${subscription.subscription.name}`, + `on the Commons plan provided by ${subscription.subscription.name}`, 'i' ), }) diff --git a/services/web/test/frontend/features/project-list/components/notifications.test.tsx b/services/web/test/frontend/features/project-list/components/notifications.test.tsx index 0aad7fcb00..3dfc27b51e 100644 --- a/services/web/test/frontend/features/project-list/components/notifications.test.tsx +++ b/services/web/test/frontend/features/project-list/components/notifications.test.tsx @@ -839,7 +839,7 @@ describe('', function () { 'You are one step away from accessing Overleaf premium features' ) expect(alert.textContent).to.contain( - `Overleaf has an Overleaf subscription. Click the confirmation link sent to ${email} to upgrade to Overleaf Pro` + `Overleaf has an Overleaf subscription. Click the confirmation link sent to ${email} to upgrade to Overleaf Commons` ) }) } diff --git a/services/web/test/frontend/features/settings/components/emails/emails-section.test.tsx b/services/web/test/frontend/features/settings/components/emails/emails-section.test.tsx index 7745aecf0f..746a4c6ead 100644 --- a/services/web/test/frontend/features/settings/components/emails/emails-section.test.tsx +++ b/services/web/test/frontend/features/settings/components/emails/emails-section.test.tsx @@ -111,14 +111,14 @@ describe('', function () { await screen.findByRole('button', { name: 'Send confirmation code' }) }) - it('renders professional label', async function () { + it('renders commons label', async function () { fetchMock.get('/user/emails?ensureAffiliation=true', [professionalUserData]) renderEmailsSection() const node = await screen.findByText(professionalUserData.email, { exact: false, }) - expect(within(node).getByText(/professional/i)).to.exist + expect(within(node).getByText(/commons/i)).to.exist }) it('shows loader when resending email', async function () { diff --git a/services/web/test/frontend/features/settings/components/emails/sso-alert.test.tsx b/services/web/test/frontend/features/settings/components/emails/sso-alert.test.tsx index 0ad5a1f11a..283d1bdaba 100644 --- a/services/web/test/frontend/features/settings/components/emails/sso-alert.test.tsx +++ b/services/web/test/frontend/features/settings/components/emails/sso-alert.test.tsx @@ -24,12 +24,12 @@ describe('', function () { screen.getByText('Overleaf University', { exact: false }) }) - it('when entitled, it should render access granted to "professional" features', function () { + it('when entitled, it should render access granted to "commons" features', function () { window.metaAttributesCache.get('ol-institutionLinked').hasEntitlement = true render() screen.getByText('this grants you access', { exact: false }) - screen.getByText('Professional') + screen.getByText('Commons') }) it('when the email is not canonical it should also render a warning alert', function () { diff --git a/services/web/test/frontend/features/subscription/components/dashboard/institution-memberships.test.tsx b/services/web/test/frontend/features/subscription/components/dashboard/institution-memberships.test.tsx index 30aa9b29de..36d690a5b0 100644 --- a/services/web/test/frontend/features/subscription/components/dashboard/institution-memberships.test.tsx +++ b/services/web/test/frontend/features/subscription/components/dashboard/institution-memberships.test.tsx @@ -49,10 +49,10 @@ describe('', function () { }) expect(elements.length).to.equal(2) expect(elements[0].textContent).to.equal( - 'You are on our Pro plan as a confirmed member of Test University' + 'You are on our Commons plan as a confirmed member of Test University' ) expect(elements[1].textContent).to.equal( - 'You are on our Pro plan as a confirmed member of Example Institution' + 'You are on our Commons plan as a confirmed member of Example Institution' ) })