mirror of
https://github.com/inventree/InvenTree
synced 2024-08-30 18:33:04 +00:00
Use IS_DEV_OR_DEMO
for playground as suggested in https://github.com/inventree/InvenTree/pull/5359#issuecomment-1654593807 (#5454)
Fixes #5452
This commit is contained in:
parent
d25e9e2b2e
commit
c796e79cf0
@ -1,6 +1,7 @@
|
||||
import { Trans } from '@lingui/macro';
|
||||
|
||||
import { DocumentationLinkItem } from '../components/items/DocumentationLinks';
|
||||
import { IS_DEV_OR_DEMO } from '../main';
|
||||
|
||||
export const footerLinks = [
|
||||
{
|
||||
@ -22,11 +23,13 @@ export const footerLinks = [
|
||||
export const navTabs = [
|
||||
{ text: <Trans>Home</Trans>, name: 'home' },
|
||||
{ text: <Trans>Dashboard</Trans>, name: 'dashboard' },
|
||||
{ text: <Trans>Playground</Trans>, name: 'playground' },
|
||||
{ text: <Trans>Parts</Trans>, name: 'parts' },
|
||||
{ text: <Trans>Stock</Trans>, name: 'stock' },
|
||||
{ text: <Trans>Build</Trans>, name: 'build' }
|
||||
];
|
||||
if (IS_DEV_OR_DEMO) {
|
||||
navTabs.push({ text: <Trans>Playground</Trans>, name: 'playground' });
|
||||
}
|
||||
|
||||
export const docLinks = {
|
||||
app: 'https://docs.inventree.org/en/latest/app/app/',
|
||||
|
@ -2,6 +2,7 @@ import { Trans, t } from '@lingui/macro';
|
||||
import { Image, Text } from '@mantine/core';
|
||||
|
||||
import { MenuLinkItem } from '../components/items/MenuLinks';
|
||||
import { IS_DEV_OR_DEMO } from '../main';
|
||||
|
||||
export const menuItems: MenuLinkItem[] = [
|
||||
{
|
||||
@ -15,11 +16,14 @@ export const menuItems: MenuLinkItem[] = [
|
||||
text: <Trans>Profile page</Trans>,
|
||||
link: '/profile/user',
|
||||
doctext: <Trans>User attributes and design settings.</Trans>
|
||||
},
|
||||
{
|
||||
}
|
||||
];
|
||||
|
||||
if (IS_DEV_OR_DEMO) {
|
||||
menuItems.push({
|
||||
id: 'playground',
|
||||
text: <Trans>Playground</Trans>,
|
||||
link: '/playground',
|
||||
highlight: true
|
||||
}
|
||||
];
|
||||
});
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user