offiaccount welcome text (#4827)

* offiaccount welcome text

* fix

* Update Image.tsx

---------

Co-authored-by: Archer <545436317@qq.com>
This commit is contained in:
heheer
2025-05-17 22:03:18 +08:00
committed by GitHub
parent 932aa28a1f
commit c6e0b5a1e7
4 changed files with 10 additions and 0 deletions

View File

@@ -923,6 +923,7 @@
"not_open": "Not Open",
"not_permission": "The current subscription package does not support team operation logs",
"not_support": "Not Supported",
"not_support_wechat_image": "WeChat image rendering is not supported",
"not_yet_introduced": "No Introduction Yet",
"open_folder": "Open Folder",
"option": "Option",

View File

@@ -922,6 +922,7 @@
"not_open": "未开启",
"not_permission": "当前订阅套餐不支持团队操作日志",
"not_support": "不支持",
"not_support_wechat_image": "暂时不支持微信图片渲染",
"not_yet_introduced": "暂无介绍",
"open_folder": "打开文件夹",
"option": "选项",

View File

@@ -922,6 +922,7 @@
"not_open": "未開啟",
"not_permission": "當前訂閱套餐不支持團隊操作日誌",
"not_support": "不支援",
"not_support_wechat_image": "暫時不支持微信圖片渲染",
"not_yet_introduced": "暫無介紹",
"open_folder": "開啟資料夾",
"option": "選項",

View File

@@ -2,8 +2,10 @@ import React, { useState } from 'react';
import { Box, type ImageProps, Skeleton } from '@chakra-ui/react';
import MyPhotoView from '@fastgpt/web/components/common/Image/PhotoView';
import { useBoolean } from 'ahooks';
import { useTranslation } from 'next-i18next';
const MdImage = ({ src, ...props }: { src?: string } & ImageProps) => {
const { t } = useTranslation();
const [isLoaded, { setTrue }] = useBoolean(false);
const [renderSrc, setRenderSrc] = useState(src);
@@ -11,6 +13,11 @@ const MdImage = ({ src, ...props }: { src?: string } & ImageProps) => {
if (src?.includes('base64') && !src.startsWith('data:image')) {
return <Box>Invalid base64 image</Box>;
}
if (props.alt?.startsWith('OFFIACCOUNT_MEDIA')) {
return <Box>{t('common:not_support_wechat_image')}</Box>;
}
return (
<Skeleton isLoaded={isLoaded}>
<MyPhotoView