mirror of
https://gitee.com/dromara/go-view.git
synced 2026-05-12 00:00:01 +08:00
fix: 修复动态导入的问题,保留 redirectComponent 配置的灵活性
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
import { IconConfig } from '../Icon/index'
|
||||
import { IconConfig } from '../Default/Icon/index'
|
||||
import { PackagesCategoryEnum } from '@/packages/index.d'
|
||||
import { ChatCategoryEnum, ChatCategoryEnumName } from '../index.d'
|
||||
|
||||
@@ -78,7 +78,7 @@ const iconList = iconNames.map(name => ({
|
||||
icon: name,
|
||||
dataset: name,
|
||||
title: name.replace('uim:', ''),
|
||||
redirectComponent: './components/Icons/Icon' // 虚拟组件路径,尾部不跟 ‘/’,相对于 /packages/index.ts 文件的位置
|
||||
redirectComponent: 'Icons/Default/Icon' // 跳转组件路径规则:packageName/categoryName/componentKey
|
||||
}))
|
||||
|
||||
export default iconList
|
||||
|
||||
+1
-1
@@ -1,5 +1,5 @@
|
||||
import { ConfigType, PackagesCategoryEnum, ChartFrameEnum } from '@/packages/index.d'
|
||||
import { ChatCategoryEnum, ChatCategoryEnumName } from '../index.d'
|
||||
import { ChatCategoryEnum, ChatCategoryEnumName } from '../../index.d'
|
||||
|
||||
export const IconConfig: ConfigType = {
|
||||
key: 'Icon',
|
||||
@@ -1,4 +1,4 @@
|
||||
import { IconConfig } from '../Icon/index'
|
||||
import { IconConfig } from '../Default/Icon/index'
|
||||
import { PackagesCategoryEnum } from '@/packages/index.d'
|
||||
import { ChatCategoryEnum, ChatCategoryEnumName } from '../index.d'
|
||||
|
||||
@@ -39,7 +39,7 @@ const iconList = iconNames.map(name => ({
|
||||
icon: name,
|
||||
dataset: name,
|
||||
title: name.replace('line-md:', ''),
|
||||
redirectComponent: './components/Icons/Icon' // 虚拟组件路径,尾部不跟 ‘/’,相对于 /packages/index.ts 文件的位置
|
||||
redirectComponent: 'Icons/Default/Icon' // 跳转组件路径规则:packageName/categoryName/componentKey
|
||||
}))
|
||||
|
||||
export default iconList
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import { IconConfig } from '../Icon/index'
|
||||
import { IconConfig } from '../Default/Icon/index'
|
||||
import { PackagesCategoryEnum } from '@/packages/index.d'
|
||||
import { ChatCategoryEnum, ChatCategoryEnumName } from '../index.d'
|
||||
|
||||
@@ -47,7 +47,7 @@ const iconList = iconNames.map(name => ({
|
||||
icon: name,
|
||||
dataset: name,
|
||||
title: name.replace('wi:', ''),
|
||||
redirectComponent: './components/Icons/Icon' // 虚拟组件路径,尾部不跟 ‘/’,相对于 /packages/index.ts 文件的位置
|
||||
redirectComponent: 'Icons/Default/Icon' // 跳转组件路径规则:packageName/categoryName/componentKey
|
||||
}))
|
||||
|
||||
export default iconList
|
||||
|
||||
@@ -53,7 +53,7 @@ const addConfig = {
|
||||
chartFrame: ChartFrameEnum.STATIC,
|
||||
title: '点击上传图片',
|
||||
image: 'upload.png',
|
||||
redirectComponent: './components/Informations/Mores/Image', // 虚拟组件路径,尾部不跟 ‘/’,相对于 /packages/index.ts 文件的位置
|
||||
redirectComponent: 'Informations/Mores/Image', // 跳转组件路径规则:packageName/categoryName/componentKey
|
||||
disabled: true,
|
||||
configEvents: {
|
||||
// 点击上传事件
|
||||
@@ -74,7 +74,7 @@ const addConfig = {
|
||||
title: e.fileName,
|
||||
image: e.url,
|
||||
dataset: e.url,
|
||||
redirectComponent: './components/Informations/Mores/Image' // 虚拟组件路径,尾部不跟 ‘/’,相对于 /packages/index.ts 文件的位置
|
||||
redirectComponent: 'Informations/Mores/Image' // 跳转组件路径规则:packageName/categoryName/componentKey
|
||||
}
|
||||
userPhotosList.unshift(newPhoto)
|
||||
// 存储在本地数据中
|
||||
|
||||
@@ -17,7 +17,7 @@ const photoConfigList = imageList.map(i => ({
|
||||
image: i.imageUrl,
|
||||
dataset: i.imageUrl,
|
||||
title: i.imageName,
|
||||
redirectComponent: './components/Informations/Mores/Image' // 虚拟组件路径,尾部不跟 ‘/’,相对于 /packages/index.ts 文件的位置
|
||||
redirectComponent: 'Informations/Mores/Image' // 跳转组件路径规则:packageName/categoryName/componentKey
|
||||
}))
|
||||
|
||||
export default photoConfigList
|
||||
|
||||
Reference in New Issue
Block a user