mirror of
https://github.com/labring/FastGPT.git
synced 2025-07-23 13:03:50 +00:00
Change embedding (#1463)
* rebuild embedding queue * dataset menu * feat: rebuild data api * feat: ui change embedding model * dataset ui * feat: rebuild index ui * rename collection
This commit is contained in:
9
packages/web/components/common/MyDivider/index.tsx
Normal file
9
packages/web/components/common/MyDivider/index.tsx
Normal file
@@ -0,0 +1,9 @@
|
||||
import React from 'react';
|
||||
import { Divider, type DividerProps } from '@chakra-ui/react';
|
||||
|
||||
const MyDivider = (props: DividerProps) => {
|
||||
const { h } = props;
|
||||
return <Divider my={4} borderBottomWidth={h || '1x'} {...props}></Divider>;
|
||||
};
|
||||
|
||||
export default MyDivider;
|
@@ -1,5 +1,5 @@
|
||||
import React from 'react';
|
||||
import { Tooltip, TooltipProps, css, useMediaQuery } from '@chakra-ui/react';
|
||||
import { Box, Tooltip, TooltipProps, css, useMediaQuery } from '@chakra-ui/react';
|
||||
|
||||
interface Props extends TooltipProps {
|
||||
forceShow?: boolean;
|
||||
@@ -9,24 +9,32 @@ const MyTooltip = ({ children, forceShow = false, shouldWrapChildren = true, ...
|
||||
const [isPc] = useMediaQuery('(min-width: 900px)');
|
||||
|
||||
return isPc || forceShow ? (
|
||||
<Tooltip
|
||||
className="tooltip"
|
||||
bg={'white'}
|
||||
arrowShadowColor={'rgba(0,0,0,0.05)'}
|
||||
hasArrow
|
||||
arrowSize={12}
|
||||
offset={[-15, 15]}
|
||||
color={'myGray.800'}
|
||||
px={4}
|
||||
py={2}
|
||||
borderRadius={'8px'}
|
||||
whiteSpace={'pre-wrap'}
|
||||
boxShadow={'1px 1px 10px rgba(0,0,0,0.2)'}
|
||||
shouldWrapChildren={shouldWrapChildren}
|
||||
{...props}
|
||||
<Box
|
||||
css={css({
|
||||
'& span': {
|
||||
display: 'block'
|
||||
}
|
||||
})}
|
||||
>
|
||||
{children}
|
||||
</Tooltip>
|
||||
<Tooltip
|
||||
className="tooltip"
|
||||
bg={'white'}
|
||||
arrowShadowColor={'rgba(0,0,0,0.05)'}
|
||||
hasArrow
|
||||
arrowSize={12}
|
||||
offset={[-15, 15]}
|
||||
color={'myGray.800'}
|
||||
px={4}
|
||||
py={2}
|
||||
borderRadius={'8px'}
|
||||
whiteSpace={'pre-wrap'}
|
||||
boxShadow={'1px 1px 10px rgba(0,0,0,0.2)'}
|
||||
shouldWrapChildren={shouldWrapChildren}
|
||||
{...props}
|
||||
>
|
||||
{children}
|
||||
</Tooltip>
|
||||
</Box>
|
||||
) : (
|
||||
<>{children}</>
|
||||
);
|
||||
|
Reference in New Issue
Block a user