feat(trading): competition feature flag and team page (#5549)
This commit is contained in:
parent
e7cb2c8276
commit
7fff33e493
@ -25,3 +25,4 @@ NX_ICEBERG_ORDERS=true
|
|||||||
# NX_PRODUCT_PERPETUALS
|
# NX_PRODUCT_PERPETUALS
|
||||||
NX_METAMASK_SNAPS=true
|
NX_METAMASK_SNAPS=true
|
||||||
NX_REFERRALS=true
|
NX_REFERRALS=true
|
||||||
|
NX_TEAM_COMPETITION=true
|
||||||
|
1
apps/trading/client-pages/teams/index.ts
Normal file
1
apps/trading/client-pages/teams/index.ts
Normal file
@ -0,0 +1 @@
|
|||||||
|
export { Teams } from './teams';
|
7
apps/trading/client-pages/teams/teams.tsx
Normal file
7
apps/trading/client-pages/teams/teams.tsx
Normal file
@ -0,0 +1,7 @@
|
|||||||
|
export const Teams = () => {
|
||||||
|
return (
|
||||||
|
<div>
|
||||||
|
<h1>Teams</h1>
|
||||||
|
</div>
|
||||||
|
);
|
||||||
|
};
|
@ -14,6 +14,7 @@ import { Withdraw } from '../client-pages/withdraw';
|
|||||||
import { Transfer } from '../client-pages/transfer';
|
import { Transfer } from '../client-pages/transfer';
|
||||||
import { Fees } from '../client-pages/fees';
|
import { Fees } from '../client-pages/fees';
|
||||||
import { Rewards } from '../client-pages/rewards';
|
import { Rewards } from '../client-pages/rewards';
|
||||||
|
import { Teams } from '../client-pages/teams';
|
||||||
import { Routes as AppRoutes } from '../lib/links';
|
import { Routes as AppRoutes } from '../lib/links';
|
||||||
import { LayoutWithSky } from '../client-pages/referrals/layout';
|
import { LayoutWithSky } from '../client-pages/referrals/layout';
|
||||||
import { Referrals } from '../client-pages/referrals/referrals';
|
import { Referrals } from '../client-pages/referrals/referrals';
|
||||||
@ -92,6 +93,12 @@ export const useRouterConfig = (): RouteObject[] => {
|
|||||||
],
|
],
|
||||||
}
|
}
|
||||||
: undefined,
|
: undefined,
|
||||||
|
featureFlags.TEAM_COMPETITION
|
||||||
|
? {
|
||||||
|
path: AppRoutes.TEAMS,
|
||||||
|
element: <Teams />,
|
||||||
|
}
|
||||||
|
: undefined,
|
||||||
{
|
{
|
||||||
path: 'fees/*',
|
path: 'fees/*',
|
||||||
element: <LayoutWithSidebar sidebar={<PortfolioSidebar />} />,
|
element: <LayoutWithSidebar sidebar={<PortfolioSidebar />} />,
|
||||||
@ -176,6 +183,7 @@ export const useRouterConfig = (): RouteObject[] => {
|
|||||||
},
|
},
|
||||||
],
|
],
|
||||||
},
|
},
|
||||||
|
|
||||||
{
|
{
|
||||||
path: '*',
|
path: '*',
|
||||||
element: <NotFound />,
|
element: <NotFound />,
|
||||||
|
@ -368,6 +368,12 @@ export const compileFeatureFlags = (refresh = false): FeatureFlags => {
|
|||||||
process.env['NX_VOLUME_DISCOUNTS']
|
process.env['NX_VOLUME_DISCOUNTS']
|
||||||
) as string
|
) as string
|
||||||
),
|
),
|
||||||
|
TEAM_COMPETITION: TRUTHY.includes(
|
||||||
|
windowOrDefault(
|
||||||
|
'NX_TEAM_COMPETITION',
|
||||||
|
process.env['NX_TEAM_COMPETITION']
|
||||||
|
) as string
|
||||||
|
),
|
||||||
};
|
};
|
||||||
|
|
||||||
const EXPLORER_FLAGS = {
|
const EXPLORER_FLAGS = {
|
||||||
|
@ -28,6 +28,7 @@ export type CosmicElevatorFlags = Pick<
|
|||||||
| 'GOVERNANCE_TRANSFERS'
|
| 'GOVERNANCE_TRANSFERS'
|
||||||
| 'VOLUME_DISCOUNTS'
|
| 'VOLUME_DISCOUNTS'
|
||||||
| 'DISABLE_CLOSE_POSITION'
|
| 'DISABLE_CLOSE_POSITION'
|
||||||
|
| 'TEAM_COMPETITION'
|
||||||
>;
|
>;
|
||||||
export type Configuration = z.infer<typeof tomlConfigSchema>;
|
export type Configuration = z.infer<typeof tomlConfigSchema>;
|
||||||
export const CUSTOM_NODE_KEY = 'custom' as const;
|
export const CUSTOM_NODE_KEY = 'custom' as const;
|
||||||
|
@ -84,6 +84,7 @@ const COSMIC_ELEVATOR_FLAGS = {
|
|||||||
GOVERNANCE_TRANSFERS: z.optional(z.boolean()),
|
GOVERNANCE_TRANSFERS: z.optional(z.boolean()),
|
||||||
VOLUME_DISCOUNTS: z.optional(z.boolean()),
|
VOLUME_DISCOUNTS: z.optional(z.boolean()),
|
||||||
DISABLE_CLOSE_POSITION: z.optional(z.boolean()),
|
DISABLE_CLOSE_POSITION: z.optional(z.boolean()),
|
||||||
|
TEAM_COMPETITION: z.optional(z.boolean()),
|
||||||
};
|
};
|
||||||
|
|
||||||
const EXPLORER_FLAGS = {
|
const EXPLORER_FLAGS = {
|
||||||
|
Loading…
Reference in New Issue
Block a user