4.8.5 test fix (#1835)

* faq

* perf: navbar name and fix dataset selector

* feat: app tag

* perf: icon

* fix: update workflow bug

* perf: dataset ui

* perf: menu

* fix: ts

* fix: auth file and app list ui

* app list

* app list

* perf: init api

* update per

* log level
This commit is contained in:
Archer
2024-06-25 10:10:24 +08:00
committed by GitHub
parent d902d29c71
commit 5c8c7fb9f2
50 changed files with 9331 additions and 12025 deletions

View File

@@ -34,7 +34,7 @@ const Navbar = ({ unread }: { unread: number }) => {
activeLink: ['/chat']
},
{
label: t('navbar.Apps'),
label: t('navbar.Studio'),
icon: 'core/app/aiLight',
activeIcon: 'core/app/aiFill',
link: `/app/list`,

View File

@@ -21,7 +21,7 @@ const NavbarPhone = ({ unread }: { unread: number }) => {
unread: 0
},
{
label: t('navbar.Apps'),
label: t('navbar.Studio'),
icon: 'core/app/aiLight',
activeIcon: 'core/app/aiFill',
link: `/app/list`,

View File

@@ -20,6 +20,7 @@ const PageContainer = ({
overflow={'overlay'}
bg={'myGray.25'}
borderRadius={[0, '16px']}
overflowX={'hidden'}
{...insertProps}
>
{children}

View File

@@ -1,43 +0,0 @@
import React, { useRef } from 'react';
import { AppTypeEnum } from '@fastgpt/global/core/app/constants';
import MyTag from '@fastgpt/web/components/common/Tag/index';
import { useI18n } from '@/web/context/I18n';
import MyIcon from '@fastgpt/web/components/common/Icon';
import { Box } from '@chakra-ui/react';
const AppTypeTag = ({ type }: { type: AppTypeEnum }) => {
const { appT } = useI18n();
const map = useRef({
[AppTypeEnum.simple]: {
label: appT('type.Simple bot'),
icon: 'core/app/type/simple'
},
[AppTypeEnum.workflow]: {
label: appT('type.Workflow bot'),
icon: 'core/app/type/workflow'
},
[AppTypeEnum.plugin]: {
label: appT('type.Plugin'),
icon: 'core/app/type/plugin'
},
[AppTypeEnum.httpPlugin]: {
label: appT('type.Http plugin'),
icon: 'core/app/type/httpPlugin'
},
[AppTypeEnum.folder]: undefined
});
const data = map.current[type];
return data ? (
<MyTag type="borderFill" colorSchema="gray">
<MyIcon name={data.icon as any} w={'0.8rem'} color={'myGray.500'} />
<Box ml={1} fontSize={'mini'}>
{data.label}
</Box>
</MyTag>
) : null;
};
export default AppTypeTag;

View File

@@ -32,7 +32,7 @@ const PermissionIconText = ({
return PermissionTypeMap[per] ? (
<Flex alignItems={'center'} fontSize={fontSize} {...props}>
<MyIcon name={PermissionTypeMap[per]?.iconLight as any} w={w} />
<Box ml={'2px'} lineHeight={1} fontSize={'xs'}>
<Box ml={'2px'} lineHeight={1}>
{t(PermissionTypeMap[per]?.label)}
</Box>
</Flex>