diff --git a/ghost/portal/jsconfig.json b/ghost/portal/jsconfig.json index bb606eefd3..5f2e866921 100644 --- a/ghost/portal/jsconfig.json +++ b/ghost/portal/jsconfig.json @@ -1,6 +1,3 @@ { - "compilerOptions": { - "baseUrl": "src" - }, "include": ["src"] } diff --git a/ghost/portal/src/components/pages/AccountHomePage/AccountHomePage.js b/ghost/portal/src/components/pages/AccountHomePage/AccountHomePage.js index a1b8013325..05dc00a0a8 100644 --- a/ghost/portal/src/components/pages/AccountHomePage/AccountHomePage.js +++ b/ghost/portal/src/components/pages/AccountHomePage/AccountHomePage.js @@ -1,6 +1,6 @@ import React from 'react'; -import AppContext from 'AppContext'; -import {getSupportAddress} from 'utils/helpers'; +import AppContext from '../../../AppContext'; +import {getSupportAddress} from '../../../utils/helpers'; import AccountFooter from './components/AccountFooter'; import AccountMain from './components/AccountMain'; diff --git a/ghost/portal/src/components/pages/AccountHomePage/AccountHomePage.test.js b/ghost/portal/src/components/pages/AccountHomePage/AccountHomePage.test.js index a6625b6e78..9bbf3b36ac 100644 --- a/ghost/portal/src/components/pages/AccountHomePage/AccountHomePage.test.js +++ b/ghost/portal/src/components/pages/AccountHomePage/AccountHomePage.test.js @@ -1,7 +1,7 @@ import React from 'react'; -import {render, fireEvent} from 'utils/test-utils'; +import {render, fireEvent} from '../../../utils/test-utils'; import AccountHomePage from './AccountHomePage'; -import {site} from 'utils/fixtures'; +import {site} from '../../../utils/fixtures'; const setup = (overrides) => { const {mockOnActionFn, ...utils} = render( diff --git a/ghost/portal/src/components/pages/AccountHomePage/components/AccountActions.js b/ghost/portal/src/components/pages/AccountHomePage/components/AccountActions.js index e6ce2b4ea4..53dd258c31 100644 --- a/ghost/portal/src/components/pages/AccountHomePage/components/AccountActions.js +++ b/ghost/portal/src/components/pages/AccountHomePage/components/AccountActions.js @@ -1,6 +1,6 @@ -import AppContext from 'AppContext'; +import AppContext from '../../../../AppContext'; import {useContext} from 'react'; -import {hasCommentsEnabled, hasMultipleNewsletters, isEmailSuppressed} from 'utils/helpers'; +import {hasCommentsEnabled, hasMultipleNewsletters, isEmailSuppressed} from '../../../../utils/helpers'; import PaidAccountActions from './PaidAccountActions'; import EmailNewsletterAction from './EmailNewsletterAction'; diff --git a/ghost/portal/src/components/pages/AccountHomePage/components/AccountMain.js b/ghost/portal/src/components/pages/AccountHomePage/components/AccountMain.js index 6c261ef1ad..b81d84b19d 100644 --- a/ghost/portal/src/components/pages/AccountHomePage/components/AccountMain.js +++ b/ghost/portal/src/components/pages/AccountHomePage/components/AccountMain.js @@ -1,4 +1,4 @@ -import CloseButton from 'components/common/CloseButton'; +import CloseButton from '../../../../components/common/CloseButton'; import UserHeader from './UserHeader'; import AccountWelcome from './AccountWelcome'; diff --git a/ghost/portal/src/components/pages/AccountHomePage/components/AccountWelcome.js b/ghost/portal/src/components/pages/AccountHomePage/components/AccountWelcome.js index 4ff8cba84e..054bfdba75 100644 --- a/ghost/portal/src/components/pages/AccountHomePage/components/AccountWelcome.js +++ b/ghost/portal/src/components/pages/AccountHomePage/components/AccountWelcome.js @@ -1,6 +1,6 @@ -import AppContext from 'AppContext'; -import {getCompExpiry, getMemberSubscription, hasOnlyFreePlan, isComplimentaryMember, subscriptionHasFreeTrial} from 'utils/helpers'; -import {getDateString} from 'utils/date-time'; +import AppContext from '../../../../AppContext'; +import {getCompExpiry, getMemberSubscription, hasOnlyFreePlan, isComplimentaryMember, subscriptionHasFreeTrial} from '../../../../utils/helpers'; +import {getDateString} from '../../../../utils/date-time'; import {useContext} from 'react'; import SubscribeButton from './SubscribeButton'; diff --git a/ghost/portal/src/components/pages/AccountHomePage/components/ContinueSubscriptionButton.js b/ghost/portal/src/components/pages/AccountHomePage/components/ContinueSubscriptionButton.js index fe26669fc2..a8fec08734 100644 --- a/ghost/portal/src/components/pages/AccountHomePage/components/ContinueSubscriptionButton.js +++ b/ghost/portal/src/components/pages/AccountHomePage/components/ContinueSubscriptionButton.js @@ -1,7 +1,7 @@ -import AppContext from 'AppContext'; -import ActionButton from 'components/common/ActionButton'; -import {getMemberSubscription} from 'utils/helpers'; -import {getDateString} from 'utils/date-time'; +import AppContext from '../../../../AppContext'; +import ActionButton from '../../../common/ActionButton'; +import {getMemberSubscription} from '../../../../utils/helpers'; +import {getDateString} from '../../../../utils/date-time'; import {useContext} from 'react'; const ContinueSubscriptionButton = () => { diff --git a/ghost/portal/src/components/pages/AccountHomePage/components/EmailNewsletterAction.js b/ghost/portal/src/components/pages/AccountHomePage/components/EmailNewsletterAction.js index 9d8307cbd4..b51348af18 100644 --- a/ghost/portal/src/components/pages/AccountHomePage/components/EmailNewsletterAction.js +++ b/ghost/portal/src/components/pages/AccountHomePage/components/EmailNewsletterAction.js @@ -1,6 +1,6 @@ -import AppContext from 'AppContext'; -import Switch from 'components/common/Switch'; -import {getSiteNewsletters, hasMemberGotEmailSuppression} from 'utils/helpers'; +import AppContext from '../../../../AppContext'; +import Switch from '../../../common/Switch'; +import {getSiteNewsletters, hasMemberGotEmailSuppression} from '../../../../utils/helpers'; import {useContext} from 'react'; function EmailNewsletterAction() { diff --git a/ghost/portal/src/components/pages/AccountHomePage/components/EmailPreferencesAction.js b/ghost/portal/src/components/pages/AccountHomePage/components/EmailPreferencesAction.js index 80d9390d49..9d9e1f099d 100644 --- a/ghost/portal/src/components/pages/AccountHomePage/components/EmailPreferencesAction.js +++ b/ghost/portal/src/components/pages/AccountHomePage/components/EmailPreferencesAction.js @@ -1,7 +1,7 @@ -import AppContext from 'AppContext'; +import AppContext from '../../../../AppContext'; import {useContext} from 'react'; -import {isEmailSuppressed} from 'utils/helpers'; -import {ReactComponent as EmailDeliveryFailedIcon} from 'images/icons/email-delivery-failed.svg'; +import {isEmailSuppressed} from '../../../../utils/helpers'; +import {ReactComponent as EmailDeliveryFailedIcon} from '../../../../images/icons/email-delivery-failed.svg'; function EmailPreferencesAction() { const {onAction, member, t} = useContext(AppContext); diff --git a/ghost/portal/src/components/pages/AccountHomePage/components/PaidAccountActions.js b/ghost/portal/src/components/pages/AccountHomePage/components/PaidAccountActions.js index e04d66f398..2809ae6e5f 100644 --- a/ghost/portal/src/components/pages/AccountHomePage/components/PaidAccountActions.js +++ b/ghost/portal/src/components/pages/AccountHomePage/components/PaidAccountActions.js @@ -1,8 +1,8 @@ -import AppContext from 'AppContext'; -import {allowCompMemberUpgrade, getCompExpiry, getMemberSubscription, getMemberTierName, getUpdatedOfferPrice, hasMultipleProductsFeature, hasOnlyFreePlan, isComplimentaryMember, isInThePast, subscriptionHasFreeTrial} from 'utils/helpers'; -import {getDateString} from 'utils/date-time'; -import {ReactComponent as LoaderIcon} from 'images/icons/loader.svg'; -import {ReactComponent as OfferTagIcon} from 'images/icons/offer-tag.svg'; +import AppContext from '../../../../AppContext'; +import {allowCompMemberUpgrade, getCompExpiry, getMemberSubscription, getMemberTierName, getUpdatedOfferPrice, hasMultipleProductsFeature, hasOnlyFreePlan, isComplimentaryMember, isInThePast, subscriptionHasFreeTrial} from '../../../../utils/helpers'; +import {getDateString} from '../../../../utils/date-time'; +import {ReactComponent as LoaderIcon} from '../../../../images/icons/loader.svg'; +import {ReactComponent as OfferTagIcon} from '../../../../images/icons/offer-tag.svg'; import {useContext} from 'react'; const PaidAccountActions = () => { diff --git a/ghost/portal/src/components/pages/AccountHomePage/components/SubscribeButton.js b/ghost/portal/src/components/pages/AccountHomePage/components/SubscribeButton.js index 633bb29ad7..bfeecf2866 100644 --- a/ghost/portal/src/components/pages/AccountHomePage/components/SubscribeButton.js +++ b/ghost/portal/src/components/pages/AccountHomePage/components/SubscribeButton.js @@ -1,6 +1,6 @@ -import AppContext from 'AppContext'; -import ActionButton from 'components/common/ActionButton'; -import {hasOnlyFreePlan} from 'utils/helpers'; +import AppContext from '../../../../AppContext'; +import ActionButton from '../../../common/ActionButton'; +import {hasOnlyFreePlan} from '../../../../utils/helpers'; import {useContext} from 'react'; const SubscribeButton = () => { diff --git a/ghost/portal/src/components/pages/AccountHomePage/components/UserHeader.js b/ghost/portal/src/components/pages/AccountHomePage/components/UserHeader.js index ab35bd4a92..fd8edbec39 100644 --- a/ghost/portal/src/components/pages/AccountHomePage/components/UserHeader.js +++ b/ghost/portal/src/components/pages/AccountHomePage/components/UserHeader.js @@ -1,5 +1,5 @@ -import AppContext from 'AppContext'; -import MemberAvatar from 'components/common/MemberGravatar'; +import AppContext from '../../../../AppContext'; +import MemberAvatar from '../../../common/MemberGravatar'; import React, {useContext} from 'react'; const UserHeader = () => { diff --git a/ghost/portal/src/components/pages/EmailReceivingFAQ.js b/ghost/portal/src/components/pages/EmailReceivingFAQ.js index 12eed2f91c..5b5f4a778e 100644 --- a/ghost/portal/src/components/pages/EmailReceivingFAQ.js +++ b/ghost/portal/src/components/pages/EmailReceivingFAQ.js @@ -1,8 +1,8 @@ -import AppContext from 'AppContext'; +import AppContext from '../../AppContext'; import {useContext} from 'react'; -import BackButton from 'components/common/BackButton'; -import CloseButton from 'components/common/CloseButton'; -import {getDefaultNewsletterSender, getSupportAddress} from 'utils/helpers'; +import BackButton from '../../components/common/BackButton'; +import CloseButton from '../../components/common/CloseButton'; +import {getDefaultNewsletterSender, getSupportAddress} from '../../utils/helpers'; export default function EmailReceivingPage() { const {brandColor, onAction, site, lastPage, member} = useContext(AppContext); diff --git a/ghost/portal/src/components/pages/EmailSuppressedPage.js b/ghost/portal/src/components/pages/EmailSuppressedPage.js index d1dc171d43..d132ab42cf 100644 --- a/ghost/portal/src/components/pages/EmailSuppressedPage.js +++ b/ghost/portal/src/components/pages/EmailSuppressedPage.js @@ -1,10 +1,10 @@ -import AppContext from 'AppContext'; +import AppContext from '../../AppContext'; import {useContext, useEffect} from 'react'; -import {hasCommentsEnabled, hasMultipleNewsletters} from 'utils/helpers'; -import CloseButton from 'components/common/CloseButton'; -import BackButton from 'components/common/BackButton'; -import ActionButton from 'components/common/ActionButton'; -import {ReactComponent as EmailDeliveryFailedIcon} from 'images/icons/email-delivery-failed.svg'; +import {hasCommentsEnabled, hasMultipleNewsletters} from '../../utils/helpers'; +import CloseButton from '../../components/common/CloseButton'; +import BackButton from '../../components/common/BackButton'; +import ActionButton from '../../components/common/ActionButton'; +import {ReactComponent as EmailDeliveryFailedIcon} from '../../images/icons/email-delivery-failed.svg'; export default function EmailSuppressedPage() { const {brandColor, lastPage, onAction, action, site, t} = useContext(AppContext); diff --git a/ghost/portal/src/components/pages/EmailSuppressedPage.test.js b/ghost/portal/src/components/pages/EmailSuppressedPage.test.js index 7b99823d65..ae28306a56 100644 --- a/ghost/portal/src/components/pages/EmailSuppressedPage.test.js +++ b/ghost/portal/src/components/pages/EmailSuppressedPage.test.js @@ -1,5 +1,5 @@ import React from 'react'; -import {render, fireEvent} from 'utils/test-utils'; +import {render, fireEvent} from '../../utils/test-utils'; import EmailSuppressedPage from './EmailSuppressedPage'; const setup = (overrides) => { diff --git a/ghost/portal/src/components/pages/EmailSuppressionFAQ.js b/ghost/portal/src/components/pages/EmailSuppressionFAQ.js index 1f5773377a..3ba7dd6083 100644 --- a/ghost/portal/src/components/pages/EmailSuppressionFAQ.js +++ b/ghost/portal/src/components/pages/EmailSuppressionFAQ.js @@ -1,8 +1,8 @@ -import AppContext from 'AppContext'; +import AppContext from '../../AppContext'; import {useContext} from 'react'; -import BackButton from 'components/common/BackButton'; -import CloseButton from 'components/common/CloseButton'; -import {getSupportAddress} from 'utils/helpers'; +import BackButton from '../../components/common/BackButton'; +import CloseButton from '../../components/common/CloseButton'; +import {getSupportAddress} from '../../utils/helpers'; export default function EmailSuppressedPage() { const {brandColor, onAction, site} = useContext(AppContext);