Compare commits
19 Commits
feat/brows
...
main
| Author | SHA1 | Date |
|---|---|---|
|
|
be57684dbf | |
|
|
1b8d1df265 | |
|
|
d56064fa2e | |
|
|
935d59dab8 | |
|
|
7f4f393ba0 | |
|
|
0ed3578565 | |
|
|
c6da027450 | |
|
|
33321c2e65 | |
|
|
96fb709505 | |
|
|
f111ee033a | |
|
|
5daff15196 | |
|
|
5b8b8f4cd4 | |
|
|
8a9d1da081 | |
|
|
69a76446d2 | |
|
|
e1ad6056fc | |
|
|
cac4f8e229 | |
|
|
01c838e869 | |
|
|
684aa404f2 | |
|
|
4ae62a96e1 |
|
After Width: | Height: | Size: 67 KiB |
|
After Width: | Height: | Size: 73 KiB |
|
After Width: | Height: | Size: 74 KiB |
|
After Width: | Height: | Size: 76 KiB |
|
After Width: | Height: | Size: 81 KiB |
|
After Width: | Height: | Size: 82 KiB |
|
After Width: | Height: | Size: 83 KiB |
|
After Width: | Height: | Size: 82 KiB |
|
After Width: | Height: | Size: 90 KiB |
|
After Width: | Height: | Size: 26 KiB |
|
After Width: | Height: | Size: 81 KiB |
|
After Width: | Height: | Size: 76 KiB |
|
After Width: | Height: | Size: 86 KiB |
|
After Width: | Height: | Size: 93 KiB |
|
After Width: | Height: | Size: 88 KiB |
|
After Width: | Height: | Size: 94 KiB |
|
After Width: | Height: | Size: 95 KiB |
|
After Width: | Height: | Size: 36 KiB |
|
After Width: | Height: | Size: 76 KiB |
|
After Width: | Height: | Size: 127 KiB |
|
After Width: | Height: | Size: 130 KiB |
|
After Width: | Height: | Size: 83 KiB |
|
After Width: | Height: | Size: 89 KiB |
|
After Width: | Height: | Size: 80 KiB |
|
After Width: | Height: | Size: 91 KiB |
|
After Width: | Height: | Size: 93 KiB |
|
After Width: | Height: | Size: 94 KiB |
|
After Width: | Height: | Size: 62 KiB |
|
After Width: | Height: | Size: 69 KiB |
|
After Width: | Height: | Size: 69 KiB |
|
After Width: | Height: | Size: 72 KiB |
|
After Width: | Height: | Size: 76 KiB |
|
After Width: | Height: | Size: 125 KiB |
|
After Width: | Height: | Size: 79 KiB |
|
After Width: | Height: | Size: 130 KiB |
|
After Width: | Height: | Size: 81 KiB |
|
After Width: | Height: | Size: 82 KiB |
|
After Width: | Height: | Size: 86 KiB |
|
After Width: | Height: | Size: 27 KiB |
|
After Width: | Height: | Size: 38 KiB |
|
|
@ -1,14 +1,6 @@
|
||||||
// First: the rules sheet reads a server-only namespace, which the server bootstrap adds to i18n
|
|
||||||
// when this module loads (0055).
|
|
||||||
import '../../../../../bootstrap/bootstrap.server';
|
|
||||||
|
|
||||||
import { SkeletonPreset } from '@lumina/island/organisms/skeleton-preset';
|
import { SkeletonPreset } from '@lumina/island/organisms/skeleton-preset';
|
||||||
import { GuestGuard } from '@lumina/market/app/guards/guest-guard';
|
import { GuestGuard } from '@lumina/market/app/guards/guest-guard';
|
||||||
import { ROUTES } from '@lumina/market/app/navigation';
|
import { ROUTES } from '@lumina/market/app/navigation';
|
||||||
import {
|
|
||||||
GeneralRules,
|
|
||||||
generalRulesLabels,
|
|
||||||
} from '@lumina/market/app/screens/organisms/general-rules';
|
|
||||||
import { RegisterDetailsStep } from '@lumina/market/app/screens/(auth)/auth/register/details/organisms/register-details-step';
|
import { RegisterDetailsStep } from '@lumina/market/app/screens/(auth)/auth/register/details/organisms/register-details-step';
|
||||||
import type { Metadata } from 'next';
|
import type { Metadata } from 'next';
|
||||||
|
|
||||||
|
|
@ -37,12 +29,6 @@ export default function RegisterDetailsPage() {
|
||||||
size="md"
|
size="md"
|
||||||
supportPlacement="popover"
|
supportPlacement="popover"
|
||||||
haltPlacement="modal"
|
haltPlacement="modal"
|
||||||
rules={
|
|
||||||
<GeneralRules
|
|
||||||
layout="sheet"
|
|
||||||
labels={generalRulesLabels(i18n.getFixedT(null, 'rules'))}
|
|
||||||
/>
|
|
||||||
}
|
|
||||||
/>
|
/>
|
||||||
</GuestGuard>
|
</GuestGuard>
|
||||||
</AuthTemplate>
|
</AuthTemplate>
|
||||||
|
|
|
||||||
|
|
@ -13,7 +13,7 @@ export const metadata: Metadata = {
|
||||||
};
|
};
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* «پیشبینی جدید» on a direct load (J09-1-D): the 960px composer under the header, in the browser
|
* «سیگنال جدید» on a direct load (J09-1-D): the 960px composer under the header, in the browser
|
||||||
* only. From a page, the `@modal` slot opens it as a dialog over that page instead (0023).
|
* only. From a page, the `@modal` slot opens it as a dialog over that page instead (0023).
|
||||||
*/
|
*/
|
||||||
export default function ComposePredictionPage() {
|
export default function ComposePredictionPage() {
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,6 @@
|
||||||
// First: the static `metadata` below reads a server-only namespace, which the server bootstrap
|
// First: the static `metadata` below reads a server-only namespace, which the server bootstrap
|
||||||
// adds to i18n when this module loads, whichever module Next loads first (0055).
|
// adds to i18n when this module loads, whichever module Next loads first (0055).
|
||||||
import '../../../bootstrap/bootstrap.server';
|
import '../../../../bootstrap/bootstrap.server';
|
||||||
|
|
||||||
import { FlexBox } from '@lumina/island/atoms/flex-box';
|
import { FlexBox } from '@lumina/island/atoms/flex-box';
|
||||||
import { DesktopHeader, DesktopPageTitle } from '@lumina/market/app/navigation';
|
import { DesktopHeader, DesktopPageTitle } from '@lumina/market/app/navigation';
|
||||||
|
|
@ -8,7 +8,7 @@ import { RulesTabs } from '@lumina/market/app/screens/(flow)/terms/organisms/rul
|
||||||
import type { Metadata } from 'next';
|
import type { Metadata } from 'next';
|
||||||
import type { ReactNode } from 'react';
|
import type { ReactNode } from 'react';
|
||||||
|
|
||||||
import { i18n } from '../../../i18n';
|
import { i18n } from '../../../../i18n';
|
||||||
|
|
||||||
// Only the landing is indexed (0071); both tabs inherit this.
|
// Only the landing is indexed (0071); both tabs inherit this.
|
||||||
export const metadata: Metadata = {
|
export const metadata: Metadata = {
|
||||||
|
|
@ -18,8 +18,8 @@ export const metadata: Metadata = {
|
||||||
};
|
};
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* «قوانین لومینا» on desktop (G-2r): the 640 column under the header, with back beside the title
|
* «قوانین و مقررات لومینا» on desktop (G-2r): the 640 column under the header, with back beside the title
|
||||||
* «قوانین لومینا» and the tab row «قوانین عمومی» · «شرایط اشتراک»; each tab's text sits in a panel.
|
* «قوانین و مقررات لومینا» and the tab row «قوانین و مقررات» · «شرایط اشتراک»; each tab's text sits in a panel.
|
||||||
* Each tab is its own route with its own loading, so the title and the row stay while one loads;
|
* Each tab is its own route with its own loading, so the title and the row stay while one loads;
|
||||||
* back returns to where the rules were opened. No nav item is active.
|
* back returns to where the rules were opened. No nav item is active.
|
||||||
*/
|
*/
|
||||||
|
|
@ -1,9 +1,9 @@
|
||||||
import { Skeleton, SkeletonRegion } from '@lumina/island/atoms/skeleton';
|
import { Skeleton, SkeletonRegion } from '@lumina/island/atoms/skeleton';
|
||||||
import { Card } from '@lumina/island/molecules/card';
|
import { Card } from '@lumina/island/molecules/card';
|
||||||
|
|
||||||
import { i18n } from '../../../i18n';
|
import { i18n } from '../../../../i18n';
|
||||||
|
|
||||||
/** «قوانین عمومی» before it arrives, under the section's title and tabs: its panel of lines. */
|
/** «قوانین و مقررات» before it arrives, under the section's title and tabs: its panel of lines. */
|
||||||
export default function Loading() {
|
export default function Loading() {
|
||||||
return (
|
return (
|
||||||
<SkeletonRegion delayed label={i18n.t('rules:meta-title')}>
|
<SkeletonRegion delayed label={i18n.t('rules:meta-title')}>
|
||||||
|
|
@ -0,0 +1,23 @@
|
||||||
|
// First: the static `metadata` below reads a server-only namespace, which the server bootstrap
|
||||||
|
// adds to i18n when this module loads, whichever module Next loads first (0055).
|
||||||
|
import '../../../../bootstrap/bootstrap.server';
|
||||||
|
|
||||||
|
import { Card } from '@lumina/island/molecules/card';
|
||||||
|
import { LegalDocumentView } from '@lumina/market/app/screens/organisms/legal-document';
|
||||||
|
import type { Metadata } from 'next';
|
||||||
|
|
||||||
|
import { i18n } from '../../../../i18n';
|
||||||
|
|
||||||
|
export const metadata: Metadata = {
|
||||||
|
title: i18n.t('rules:meta-title'),
|
||||||
|
description: i18n.t('rules:meta-description'),
|
||||||
|
};
|
||||||
|
|
||||||
|
/** «قوانین و مقررات», the first tab of «قوانین و مقررات لومینا» (G-2r); its text is read in the browser (0070). */
|
||||||
|
export default function RulesPage() {
|
||||||
|
return (
|
||||||
|
<Card padding="lg">
|
||||||
|
<LegalDocumentView documentKey="platform_rules" layout="desktop" />
|
||||||
|
</Card>
|
||||||
|
);
|
||||||
|
}
|
||||||
|
|
@ -1,7 +1,7 @@
|
||||||
import { Skeleton, SkeletonRegion } from '@lumina/island/atoms/skeleton';
|
import { Skeleton, SkeletonRegion } from '@lumina/island/atoms/skeleton';
|
||||||
import { Card } from '@lumina/island/molecules/card';
|
import { Card } from '@lumina/island/molecules/card';
|
||||||
|
|
||||||
import { i18n } from '../../../../i18n';
|
import { i18n } from '../../../../../i18n';
|
||||||
|
|
||||||
/** The terms before they arrive, under the section's title and tabs: their panel of lines. */
|
/** The terms before they arrive, under the section's title and tabs: their panel of lines. */
|
||||||
export default function Loading() {
|
export default function Loading() {
|
||||||
|
|
@ -0,0 +1,23 @@
|
||||||
|
// First: the static `metadata` below reads a server-only namespace, which the server bootstrap
|
||||||
|
// adds to i18n when this module loads, whichever module Next loads first (0055).
|
||||||
|
import '../../../../../bootstrap/bootstrap.server';
|
||||||
|
|
||||||
|
import { Card } from '@lumina/island/molecules/card';
|
||||||
|
import { SubscriptionTerms } from '@lumina/market/app/screens/(flow)/terms/subscription/organisms/subscription-terms';
|
||||||
|
import type { Metadata } from 'next';
|
||||||
|
|
||||||
|
import { i18n } from '../../../../../i18n';
|
||||||
|
|
||||||
|
export const metadata: Metadata = {
|
||||||
|
title: i18n.t('terms:meta-title'),
|
||||||
|
description: i18n.t('terms:meta-description'),
|
||||||
|
};
|
||||||
|
|
||||||
|
/** «شرایط اشتراک», the second tab of «قوانین و مقررات لومینا» (S5, G-2); its text is read in the browser (0070). */
|
||||||
|
export default function SubscriptionTermsPage() {
|
||||||
|
return (
|
||||||
|
<Card padding="lg">
|
||||||
|
<SubscriptionTerms layout="desktop" />
|
||||||
|
</Card>
|
||||||
|
);
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,44 @@
|
||||||
|
// First: the static `metadata` below reads a server-only namespace, which the server bootstrap
|
||||||
|
// adds to i18n when this module loads, whichever module Next loads first (0055).
|
||||||
|
import '../../../../bootstrap/bootstrap.server';
|
||||||
|
|
||||||
|
import { FlexBox } from '@lumina/island/atoms/flex-box';
|
||||||
|
import { DesktopHeader, DesktopPageTitle } from '@lumina/market/app/navigation';
|
||||||
|
import type { Metadata } from 'next';
|
||||||
|
import type { ReactNode } from 'react';
|
||||||
|
|
||||||
|
import { i18n } from '../../../../i18n';
|
||||||
|
|
||||||
|
export const metadata: Metadata = {
|
||||||
|
title: i18n.t('rules:agreement.meta-title'),
|
||||||
|
robots: { index: false },
|
||||||
|
};
|
||||||
|
|
||||||
|
/** «توافقنامه تحلیلگر» on desktop: the 640 column under the header, with back beside the title. */
|
||||||
|
export default function AnalystAgreementLayout({
|
||||||
|
children,
|
||||||
|
}: {
|
||||||
|
children: ReactNode;
|
||||||
|
}) {
|
||||||
|
const t = i18n.getFixedT(null, 'rules');
|
||||||
|
|
||||||
|
return (
|
||||||
|
<FlexBox direction="flex-col" className="min-h-dvh bg-bg-page">
|
||||||
|
<DesktopHeader />
|
||||||
|
<FlexBox
|
||||||
|
tag="main"
|
||||||
|
justifyContent="justify-center"
|
||||||
|
className="px-8 py-10"
|
||||||
|
>
|
||||||
|
<FlexBox
|
||||||
|
direction="flex-col"
|
||||||
|
gap="gap-4"
|
||||||
|
className="w-full max-w-content"
|
||||||
|
>
|
||||||
|
<DesktopPageTitle title={t('agreement.title')} />
|
||||||
|
{children}
|
||||||
|
</FlexBox>
|
||||||
|
</FlexBox>
|
||||||
|
</FlexBox>
|
||||||
|
);
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,8 @@
|
||||||
|
import { LegalDocumentSkeleton } from '@lumina/market/app/screens/organisms/legal-document';
|
||||||
|
|
||||||
|
import { i18n } from '../../../../i18n';
|
||||||
|
|
||||||
|
/** The agreement before it arrives, under the page's bar or title. */
|
||||||
|
export default function Loading() {
|
||||||
|
return <LegalDocumentSkeleton label={i18n.t('legal:document.loading')} />;
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,22 @@
|
||||||
|
import { Card } from '@lumina/island/molecules/card';
|
||||||
|
import { AuthGuard } from '@lumina/market/app/guards/auth-guard';
|
||||||
|
import { AnalystAgreement } from '@lumina/market/app/screens/(flow)/terms/analyst-agreement/organisms/analyst-agreement';
|
||||||
|
import { LegalDocumentSkeleton } from '@lumina/market/app/screens/organisms/legal-document';
|
||||||
|
|
||||||
|
import { i18n } from '../../../../i18n';
|
||||||
|
|
||||||
|
/** The agreement and the analyst's own record; both read in the browser (0070). Analysts only. */
|
||||||
|
export default function AnalystAgreementPage() {
|
||||||
|
return (
|
||||||
|
<AuthGuard
|
||||||
|
role="creator"
|
||||||
|
fallback={
|
||||||
|
<LegalDocumentSkeleton label={i18n.t('legal:document.loading')} />
|
||||||
|
}
|
||||||
|
>
|
||||||
|
<Card padding="lg">
|
||||||
|
<AnalystAgreement layout="desktop" />
|
||||||
|
</Card>
|
||||||
|
</AuthGuard>
|
||||||
|
);
|
||||||
|
}
|
||||||
|
|
@ -1,29 +0,0 @@
|
||||||
// First: the static `metadata` below reads a server-only namespace, which the server bootstrap
|
|
||||||
// adds to i18n when this module loads, whichever module Next loads first (0055).
|
|
||||||
import '../../../bootstrap/bootstrap.server';
|
|
||||||
|
|
||||||
import { Card } from '@lumina/island/molecules/card';
|
|
||||||
import {
|
|
||||||
GeneralRules,
|
|
||||||
generalRulesLabels,
|
|
||||||
} from '@lumina/market/app/screens/organisms/general-rules';
|
|
||||||
import type { Metadata } from 'next';
|
|
||||||
|
|
||||||
import { i18n } from '../../../i18n';
|
|
||||||
|
|
||||||
export const metadata: Metadata = {
|
|
||||||
title: i18n.t('rules:meta-title'),
|
|
||||||
description: i18n.t('rules:meta-description'),
|
|
||||||
};
|
|
||||||
|
|
||||||
/** «قوانین عمومی», the first tab of «قوانین لومینا» on desktop (G-2r): the text in a panel. */
|
|
||||||
export default function GeneralRulesPage() {
|
|
||||||
return (
|
|
||||||
<Card padding="lg">
|
|
||||||
<GeneralRules
|
|
||||||
layout="desktop"
|
|
||||||
labels={generalRulesLabels(i18n.getFixedT(null, 'rules'))}
|
|
||||||
/>
|
|
||||||
</Card>
|
|
||||||
);
|
|
||||||
}
|
|
||||||
|
|
@ -1,41 +0,0 @@
|
||||||
// First: the static `metadata` below reads a server-only namespace, which the server bootstrap
|
|
||||||
// adds to i18n when this module loads, whichever module Next loads first (0055).
|
|
||||||
import '../../../../bootstrap/bootstrap.server';
|
|
||||||
|
|
||||||
import { Card } from '@lumina/island/molecules/card';
|
|
||||||
import {
|
|
||||||
SubscriptionTerms,
|
|
||||||
subscriptionTermsLabels,
|
|
||||||
} from '@lumina/market/app/screens/(flow)/terms/subscription/organisms/subscription-terms';
|
|
||||||
import { supportChatUrls } from '@lumina/market/app/screens/organisms/support-entry';
|
|
||||||
import { getEnv } from '@lumina/market/env';
|
|
||||||
import type { Metadata } from 'next';
|
|
||||||
|
|
||||||
import { i18n } from '../../../../i18n';
|
|
||||||
|
|
||||||
export const metadata: Metadata = {
|
|
||||||
title: i18n.t('terms:meta-title'),
|
|
||||||
description: i18n.t('terms:meta-description'),
|
|
||||||
};
|
|
||||||
|
|
||||||
/**
|
|
||||||
* «شرایط اشتراک», the second tab of «قوانین لومینا» on desktop (S5 ۲.۱, G-2): the text in a panel
|
|
||||||
* of the section's 640 column, about 75 characters a line; the title and tabs come from the layout.
|
|
||||||
*/
|
|
||||||
export default function SubscriptionTermsPage() {
|
|
||||||
const labels = subscriptionTermsLabels(
|
|
||||||
i18n.getFixedT(null, 'terms'),
|
|
||||||
i18n.getFixedT(null, 'auth'),
|
|
||||||
getEnv().supportHours,
|
|
||||||
);
|
|
||||||
|
|
||||||
return (
|
|
||||||
<Card padding="lg">
|
|
||||||
<SubscriptionTerms
|
|
||||||
layout="desktop"
|
|
||||||
chats={supportChatUrls()}
|
|
||||||
labels={labels}
|
|
||||||
/>
|
|
||||||
</Card>
|
|
||||||
);
|
|
||||||
}
|
|
||||||
|
|
@ -5,7 +5,7 @@ import {
|
||||||
} from '@lumina/market/app/screens/(flow)/compose/prediction/organisms/prediction-composer';
|
} from '@lumina/market/app/screens/(flow)/compose/prediction/organisms/prediction-composer';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* «پیشبینی جدید» opened from a main page (J09-1-D, 0023): the 960px composer dialog over that
|
* «سیگنال جدید» opened from a main page (J09-1-D, 0023): the 960px composer dialog over that
|
||||||
* page, the URL /compose/prediction; a direct load of that URL gets the full page instead. In the
|
* page, the URL /compose/prediction; a direct load of that URL gets the full page instead. In the
|
||||||
* browser only: the dialog's skeleton until the viewer is known, then the composer for a creator
|
* browser only: the dialog's skeleton until the viewer is known, then the composer for a creator
|
||||||
* who may publish, why not for one who may not, or the no-access state for anyone else.
|
* who may publish, why not for one who may not, or the no-access state for anyone else.
|
||||||
|
|
|
||||||
|
|
@ -8,7 +8,7 @@ import { i18n } from '../../../../i18n';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* The creator's داشبورد on desktop (Creator Dashboard ۵.۱): the 640 column under the header, with
|
* The creator's داشبورد on desktop (Creator Dashboard ۵.۱): the 640 column under the header, with
|
||||||
* the «داشبورد» heading, the three tabs «طرحهای اشتراک» · «پیشبینیها» · «مالی», then the tab. Each tab is its own
|
* the «داشبورد» heading, the four tabs «نمای کلی» · «طرحهای اشتراک» · «سیگنالها» · «مالی», then the tab. Each tab is its own
|
||||||
* route with its own loading, so the heading and the tabs stay while one loads. Locked until
|
* route with its own loading, so the heading and the tabs stay while one loads. Locked until
|
||||||
* registration step 5 is done (0016).
|
* registration step 5 is done (0016).
|
||||||
*/
|
*/
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,14 @@
|
||||||
|
import { DashboardOverviewSkeleton } from '@lumina/market/app/screens/(main)/dashboard/overview/organisms/dashboard-overview';
|
||||||
|
|
||||||
|
import { i18n } from '../../../../../i18n';
|
||||||
|
|
||||||
|
/** نمای کلی before it arrives; the layout keeps the bar and the tabs. */
|
||||||
|
export default function Loading() {
|
||||||
|
return (
|
||||||
|
<DashboardOverviewSkeleton
|
||||||
|
layout="desktop"
|
||||||
|
label={i18n.t('dashboard:overview.loading')}
|
||||||
|
delayed
|
||||||
|
/>
|
||||||
|
);
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,42 @@
|
||||||
|
import { PartBoundary } from '@lumina/market/app/error-boundaries';
|
||||||
|
import { AuthGuard } from '@lumina/market/app/guards/auth-guard';
|
||||||
|
import {
|
||||||
|
DashboardOverview,
|
||||||
|
DashboardOverviewSkeleton,
|
||||||
|
} from '@lumina/market/app/screens/(main)/dashboard/overview/organisms/dashboard-overview';
|
||||||
|
import type { Metadata } from 'next';
|
||||||
|
import { Suspense } from 'react';
|
||||||
|
|
||||||
|
import { i18n } from '../../../../../i18n';
|
||||||
|
|
||||||
|
export const metadata: Metadata = {
|
||||||
|
title: i18n.t('dashboard:overview.meta-title'),
|
||||||
|
robots: { index: false },
|
||||||
|
};
|
||||||
|
|
||||||
|
/**
|
||||||
|
* داشبورد › نمای کلی (J10-0), the creator's default tab: audience, income, the split by plan and
|
||||||
|
* the signals' summary, the creator's own, in the browser only. The tabs stay while it loads.
|
||||||
|
*/
|
||||||
|
export default function OverviewPage() {
|
||||||
|
const skeleton = (
|
||||||
|
<DashboardOverviewSkeleton
|
||||||
|
layout="desktop"
|
||||||
|
label={i18n.t('dashboard:overview.loading')}
|
||||||
|
/>
|
||||||
|
);
|
||||||
|
|
||||||
|
return (
|
||||||
|
<AuthGuard role="creator" fallback={skeleton}>
|
||||||
|
<PartBoundary
|
||||||
|
name="dashboard-overview"
|
||||||
|
description={i18n.t('dashboard:overview.error')}
|
||||||
|
framed
|
||||||
|
>
|
||||||
|
<Suspense fallback={skeleton}>
|
||||||
|
<DashboardOverview layout="desktop" />
|
||||||
|
</Suspense>
|
||||||
|
</PartBoundary>
|
||||||
|
</AuthGuard>
|
||||||
|
);
|
||||||
|
}
|
||||||
|
|
@ -1,7 +1,7 @@
|
||||||
import { FlexBox } from '@lumina/island/atoms/flex-box';
|
import { FlexBox } from '@lumina/island/atoms/flex-box';
|
||||||
import { AudienceStatsSkeleton } from '@lumina/market/app/screens/(main)/dashboard/plans/organisms/audience-stats';
|
|
||||||
import { InviteCodeCardSkeleton } from '@lumina/market/app/screens/(main)/dashboard/plans/organisms/invite-code-card';
|
import { InviteCodeCardSkeleton } from '@lumina/market/app/screens/(main)/dashboard/plans/organisms/invite-code-card';
|
||||||
import { PricingCardSkeleton } from '@lumina/market/app/screens/(main)/dashboard/plans/organisms/pricing-card';
|
import { PricingCardSkeleton } from '@lumina/market/app/screens/(main)/dashboard/plans/organisms/pricing-card';
|
||||||
|
import { SubscribersPreviewSkeleton } from '@lumina/market/app/screens/(main)/dashboard/plans/organisms/subscribers-preview';
|
||||||
|
|
||||||
import { i18n } from '../../../../../i18n';
|
import { i18n } from '../../../../../i18n';
|
||||||
|
|
||||||
|
|
@ -19,8 +19,8 @@ export default function Loading() {
|
||||||
label={i18n.t('dashboard:invite.loading')}
|
label={i18n.t('dashboard:invite.loading')}
|
||||||
delayed
|
delayed
|
||||||
/>
|
/>
|
||||||
<AudienceStatsSkeleton
|
<SubscribersPreviewSkeleton
|
||||||
label={i18n.t('dashboard:audience.loading')}
|
label={i18n.t('dashboard:subscribers.loading')}
|
||||||
delayed
|
delayed
|
||||||
/>
|
/>
|
||||||
</FlexBox>
|
</FlexBox>
|
||||||
|
|
|
||||||
|
|
@ -1,10 +1,6 @@
|
||||||
import { FlexBox } from '@lumina/island/atoms/flex-box';
|
import { FlexBox } from '@lumina/island/atoms/flex-box';
|
||||||
import { PartBoundary } from '@lumina/market/app/error-boundaries';
|
import { PartBoundary } from '@lumina/market/app/error-boundaries';
|
||||||
import { AuthGuard } from '@lumina/market/app/guards/auth-guard';
|
import { AuthGuard } from '@lumina/market/app/guards/auth-guard';
|
||||||
import {
|
|
||||||
AudienceStats,
|
|
||||||
AudienceStatsSkeleton,
|
|
||||||
} from '@lumina/market/app/screens/(main)/dashboard/plans/organisms/audience-stats';
|
|
||||||
import {
|
import {
|
||||||
InviteCodeCard,
|
InviteCodeCard,
|
||||||
InviteCodeCardSkeleton,
|
InviteCodeCardSkeleton,
|
||||||
|
|
@ -13,6 +9,10 @@ import {
|
||||||
PricingCard,
|
PricingCard,
|
||||||
PricingCardSkeleton,
|
PricingCardSkeleton,
|
||||||
} from '@lumina/market/app/screens/(main)/dashboard/plans/organisms/pricing-card';
|
} from '@lumina/market/app/screens/(main)/dashboard/plans/organisms/pricing-card';
|
||||||
|
import {
|
||||||
|
SubscribersPreview,
|
||||||
|
SubscribersPreviewSkeleton,
|
||||||
|
} from '@lumina/market/app/screens/(main)/dashboard/plans/organisms/subscribers-preview';
|
||||||
import type { Metadata } from 'next';
|
import type { Metadata } from 'next';
|
||||||
import { Suspense } from 'react';
|
import { Suspense } from 'react';
|
||||||
|
|
||||||
|
|
@ -25,7 +25,7 @@ export const metadata: Metadata = {
|
||||||
};
|
};
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* داشبورد › طرحهای اشتراک (J10-1): «قیمت طرحها», «کد دعوت» (only once approved) and «مخاطبان»,
|
* داشبورد › طرحهای اشتراک (J10-1): «قیمت طرحها», «کد دعوت» (only once approved) and «مشترکان»,
|
||||||
* the creator's own, in the browser only. Each block loads and fails on its own; the tabs stay.
|
* the creator's own, in the browser only. Each block loads and fails on its own; the tabs stay.
|
||||||
*/
|
*/
|
||||||
export default function PlansPage() {
|
export default function PlansPage() {
|
||||||
|
|
@ -41,8 +41,10 @@ export default function PlansPage() {
|
||||||
label={i18n.t('dashboard:invite.loading')}
|
label={i18n.t('dashboard:invite.loading')}
|
||||||
/>
|
/>
|
||||||
);
|
);
|
||||||
const audienceSkeleton = (
|
const subscribersSkeleton = (
|
||||||
<AudienceStatsSkeleton label={i18n.t('dashboard:audience.loading')} />
|
<SubscribersPreviewSkeleton
|
||||||
|
label={i18n.t('dashboard:subscribers.loading')}
|
||||||
|
/>
|
||||||
);
|
);
|
||||||
|
|
||||||
return (
|
return (
|
||||||
|
|
@ -52,7 +54,7 @@ export default function PlansPage() {
|
||||||
<FlexBox direction="flex-col" gap="gap-4">
|
<FlexBox direction="flex-col" gap="gap-4">
|
||||||
{pricingSkeleton}
|
{pricingSkeleton}
|
||||||
{inviteSkeleton}
|
{inviteSkeleton}
|
||||||
{audienceSkeleton}
|
{subscribersSkeleton}
|
||||||
</FlexBox>
|
</FlexBox>
|
||||||
}
|
}
|
||||||
>
|
>
|
||||||
|
|
@ -79,12 +81,12 @@ export default function PlansPage() {
|
||||||
</Suspense>
|
</Suspense>
|
||||||
</PartBoundary>
|
</PartBoundary>
|
||||||
<PartBoundary
|
<PartBoundary
|
||||||
name="audience-stats"
|
name="subscribers-preview"
|
||||||
description={i18n.t('dashboard:audience.error')}
|
description={i18n.t('dashboard:subscribers.error')}
|
||||||
framed
|
framed
|
||||||
>
|
>
|
||||||
<Suspense fallback={audienceSkeleton}>
|
<Suspense fallback={subscribersSkeleton}>
|
||||||
<AudienceStats />
|
<SubscribersPreview />
|
||||||
</Suspense>
|
</Suspense>
|
||||||
</PartBoundary>
|
</PartBoundary>
|
||||||
</FlexBox>
|
</FlexBox>
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@ import { PredictionsTabSkeleton } from '@lumina/market/app/screens/(main)/dashbo
|
||||||
|
|
||||||
import { i18n } from '../../../../../i18n';
|
import { i18n } from '../../../../../i18n';
|
||||||
|
|
||||||
/** پیشبینیها before it arrives, block for block; the layout keeps the bar and the tabs. */
|
/** سیگنالها before it arrives, block for block; the layout keeps the bar and the tabs. */
|
||||||
export default function Loading() {
|
export default function Loading() {
|
||||||
return (
|
return (
|
||||||
<PredictionsTabSkeleton label={i18n.t('predictions:tab.loading')} delayed />
|
<PredictionsTabSkeleton label={i18n.t('predictions:tab.loading')} delayed />
|
||||||
|
|
|
||||||
|
|
@ -13,7 +13,7 @@ export const metadata: Metadata = {
|
||||||
};
|
};
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* داشبورد › پیشبینیها (J10-3): the creator's record, open and recently closed predictions, in the
|
* داشبورد › سیگنالها (J10-3): the creator's record, open and recently closed predictions, in the
|
||||||
* browser only. Each block loads and fails on its own; the tabs stay.
|
* browser only. Each block loads and fails on its own; the tabs stay.
|
||||||
*/
|
*/
|
||||||
export default function PredictionsPage() {
|
export default function PredictionsPage() {
|
||||||
|
|
|
||||||
|
|
@ -4,7 +4,7 @@ import { PredictionListSkeleton } from '@lumina/market/app/screens/(main)/dashbo
|
||||||
|
|
||||||
import { i18n } from '../../../../../i18n';
|
import { i18n } from '../../../../../i18n';
|
||||||
|
|
||||||
/** «همه پیشبینیها» before it arrives, under its real title. */
|
/** «همه سیگنالها» before it arrives, under its real title. */
|
||||||
export default function Loading() {
|
export default function Loading() {
|
||||||
return (
|
return (
|
||||||
<FlexBox tag="main" justifyContent="justify-center" className="px-8 py-10">
|
<FlexBox tag="main" justifyContent="justify-center" className="px-8 py-10">
|
||||||
|
|
|
||||||
|
|
@ -17,8 +17,8 @@ export const metadata: Metadata = {
|
||||||
};
|
};
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* «همه پیشبینیها» on desktop (J10-3f): the same list in the 640 column, «بازگشت» over its title
|
* «همه سیگنالها» on desktop (J10-3f): the same list in the 640 column, «بازگشت» over its title
|
||||||
* back to the پیشبینیها tab. The creator's own, in the browser only.
|
* back to the سیگنالها tab. The creator's own, in the browser only.
|
||||||
*/
|
*/
|
||||||
export default function PredictionListPage() {
|
export default function PredictionListPage() {
|
||||||
const skeleton = (
|
const skeleton = (
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,3 @@
|
||||||
|
// Locked until a creator finishes registration step 5 (0016), as the tab is; the guard renders
|
||||||
|
// the page as is.
|
||||||
|
export { OnboardingGuard as default } from '@lumina/market/app/guards/onboarding-guard';
|
||||||
|
|
@ -0,0 +1,27 @@
|
||||||
|
import { FlexBox } from '@lumina/island/atoms/flex-box';
|
||||||
|
import { DesktopPageTitle, ROUTES } from '@lumina/market/app/navigation';
|
||||||
|
import { SubscriberListSkeleton } from '@lumina/market/app/screens/(main)/dashboard/subscribers/organisms/subscriber-list';
|
||||||
|
|
||||||
|
import { i18n } from '../../../../i18n';
|
||||||
|
|
||||||
|
/** «مشترکان» before it arrives, under its real title. */
|
||||||
|
export default function Loading() {
|
||||||
|
return (
|
||||||
|
<FlexBox tag="main" justifyContent="justify-center" className="px-8 py-10">
|
||||||
|
<FlexBox
|
||||||
|
direction="flex-col"
|
||||||
|
gap="gap-4"
|
||||||
|
className="w-full max-w-content"
|
||||||
|
>
|
||||||
|
<DesktopPageTitle
|
||||||
|
title={i18n.t('dashboard:subscribers.title')}
|
||||||
|
parentHref={ROUTES.dashboard.overview}
|
||||||
|
/>
|
||||||
|
<SubscriberListSkeleton
|
||||||
|
label={i18n.t('dashboard:subscribers.loading')}
|
||||||
|
delayed
|
||||||
|
/>
|
||||||
|
</FlexBox>
|
||||||
|
</FlexBox>
|
||||||
|
);
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,53 @@
|
||||||
|
import { FlexBox } from '@lumina/island/atoms/flex-box';
|
||||||
|
import { PartBoundary } from '@lumina/market/app/error-boundaries';
|
||||||
|
import { AuthGuard } from '@lumina/market/app/guards/auth-guard';
|
||||||
|
import { DesktopPageTitle, ROUTES } from '@lumina/market/app/navigation';
|
||||||
|
import {
|
||||||
|
SubscriberList,
|
||||||
|
SubscriberListSkeleton,
|
||||||
|
} from '@lumina/market/app/screens/(main)/dashboard/subscribers/organisms/subscriber-list';
|
||||||
|
import type { Metadata } from 'next';
|
||||||
|
import { Suspense } from 'react';
|
||||||
|
|
||||||
|
import { i18n } from '../../../../i18n';
|
||||||
|
|
||||||
|
export const metadata: Metadata = {
|
||||||
|
title: i18n.t('dashboard:subscribers.meta-title'),
|
||||||
|
robots: { index: false },
|
||||||
|
};
|
||||||
|
|
||||||
|
/**
|
||||||
|
* «مشترکان» on desktop (J10-1f, J10-1g): the same list in the 640 column, «بازگشت» over its title
|
||||||
|
* back to نمای کلی. The creator's own, in the browser only.
|
||||||
|
*/
|
||||||
|
export default function SubscribersPage() {
|
||||||
|
const skeleton = (
|
||||||
|
<SubscriberListSkeleton label={i18n.t('dashboard:subscribers.loading')} />
|
||||||
|
);
|
||||||
|
|
||||||
|
return (
|
||||||
|
<FlexBox tag="main" justifyContent="justify-center" className="px-8 py-10">
|
||||||
|
<FlexBox
|
||||||
|
direction="flex-col"
|
||||||
|
gap="gap-4"
|
||||||
|
className="w-full max-w-content"
|
||||||
|
>
|
||||||
|
<DesktopPageTitle
|
||||||
|
title={i18n.t('dashboard:subscribers.title')}
|
||||||
|
parentHref={ROUTES.dashboard.overview}
|
||||||
|
/>
|
||||||
|
<PartBoundary
|
||||||
|
name="subscriber-list"
|
||||||
|
description={i18n.t('dashboard:subscribers.error')}
|
||||||
|
framed
|
||||||
|
>
|
||||||
|
<AuthGuard role="creator" fallback={skeleton}>
|
||||||
|
<Suspense fallback={skeleton}>
|
||||||
|
<SubscriberList />
|
||||||
|
</Suspense>
|
||||||
|
</AuthGuard>
|
||||||
|
</PartBoundary>
|
||||||
|
</FlexBox>
|
||||||
|
</FlexBox>
|
||||||
|
);
|
||||||
|
}
|
||||||
|
|
@ -12,7 +12,7 @@ import type { AppProvidersProps } from './types';
|
||||||
/** The app's root client component: runs the client bootstrap, then the platform's shell. */
|
/** The app's root client component: runs the client bootstrap, then the platform's shell. */
|
||||||
export function AppProviders({ children }: AppProvidersProps) {
|
export function AppProviders({ children }: AppProvidersProps) {
|
||||||
return (
|
return (
|
||||||
<AppShell queryClient={getQueryClient()} i18n={i18n}>
|
<AppShell queryClient={getQueryClient()} i18n={i18n} layout="desktop">
|
||||||
{children}
|
{children}
|
||||||
</AppShell>
|
</AppShell>
|
||||||
);
|
);
|
||||||
|
|
|
||||||
|
|
@ -9,6 +9,7 @@ import {
|
||||||
AUTH_EVENTS,
|
AUTH_EVENTS,
|
||||||
endSuspendedSession,
|
endSuspendedSession,
|
||||||
isSessionSuspended,
|
isSessionSuspended,
|
||||||
|
noteAgreementRequired,
|
||||||
suspendedSessionOf,
|
suspendedSessionOf,
|
||||||
} from '@lumina/market/features/auth';
|
} from '@lumina/market/features/auth';
|
||||||
|
|
||||||
|
|
@ -45,6 +46,7 @@ http.configure({
|
||||||
http.interceptors.response.use(undefined, (error) => {
|
http.interceptors.response.use(undefined, (error) => {
|
||||||
const suspension = suspendedSessionOf(error);
|
const suspension = suspendedSessionOf(error);
|
||||||
if (suspension) endSuspendedSession(suspension);
|
if (suspension) endSuspendedSession(suspension);
|
||||||
|
noteAgreementRequired(error);
|
||||||
return error;
|
return error;
|
||||||
});
|
});
|
||||||
configureErrorHandler(ERROR_HANDLER_CONFIG);
|
configureErrorHandler(ERROR_HANDLER_CONFIG);
|
||||||
|
|
|
||||||
|
|
@ -1,12 +1,17 @@
|
||||||
|
import { APPLE_WEB_APP } from '@lumina/market/server';
|
||||||
import type { Metadata } from 'next';
|
import type { Metadata } from 'next';
|
||||||
|
|
||||||
import { clientEnv } from '../env';
|
import { clientEnv } from '../env';
|
||||||
import { i18n } from '../i18n';
|
import { i18n } from '../i18n';
|
||||||
|
|
||||||
/** The root metadata: the brand as the title template, and absolute URLs from the site address. */
|
/**
|
||||||
|
* The root metadata: the brand as the title template, absolute URLs from the site address, and
|
||||||
|
* iOS's splash screens.
|
||||||
|
*/
|
||||||
export function rootMetadata(): Metadata {
|
export function rootMetadata(): Metadata {
|
||||||
const name = i18n.t('app.name');
|
const name = i18n.t('app.name');
|
||||||
return {
|
return {
|
||||||
|
...APPLE_WEB_APP,
|
||||||
metadataBase: new URL(clientEnv.NEXT_PUBLIC_SITE_URL),
|
metadataBase: new URL(clientEnv.NEXT_PUBLIC_SITE_URL),
|
||||||
title: { default: name, template: `%s · ${name}` },
|
title: { default: name, template: `%s · ${name}` },
|
||||||
description: i18n.t('app.description'),
|
description: i18n.t('app.description'),
|
||||||
|
|
|
||||||
|
After Width: | Height: | Size: 67 KiB |
|
After Width: | Height: | Size: 73 KiB |
|
After Width: | Height: | Size: 74 KiB |
|
After Width: | Height: | Size: 76 KiB |
|
After Width: | Height: | Size: 81 KiB |
|
After Width: | Height: | Size: 82 KiB |
|
After Width: | Height: | Size: 83 KiB |
|
After Width: | Height: | Size: 82 KiB |
|
After Width: | Height: | Size: 90 KiB |
|
After Width: | Height: | Size: 26 KiB |
|
After Width: | Height: | Size: 81 KiB |
|
After Width: | Height: | Size: 76 KiB |
|
After Width: | Height: | Size: 86 KiB |
|
After Width: | Height: | Size: 93 KiB |
|
After Width: | Height: | Size: 88 KiB |
|
After Width: | Height: | Size: 94 KiB |
|
After Width: | Height: | Size: 95 KiB |
|
After Width: | Height: | Size: 36 KiB |
|
After Width: | Height: | Size: 76 KiB |
|
After Width: | Height: | Size: 127 KiB |
|
After Width: | Height: | Size: 130 KiB |
|
After Width: | Height: | Size: 83 KiB |
|
After Width: | Height: | Size: 89 KiB |
|
After Width: | Height: | Size: 80 KiB |
|
After Width: | Height: | Size: 91 KiB |
|
After Width: | Height: | Size: 93 KiB |
|
After Width: | Height: | Size: 94 KiB |
|
After Width: | Height: | Size: 62 KiB |
|
After Width: | Height: | Size: 69 KiB |
|
After Width: | Height: | Size: 69 KiB |
|
After Width: | Height: | Size: 72 KiB |
|
After Width: | Height: | Size: 76 KiB |