Commit ed213d878b78697f0bdb69cb474dfab45972b2cb

Authored by vben
1 parent e09e0a12

fix(sider): mix mode adaptation in the left menu

CHANGELOG.zh_CN.md
... ... @@ -25,6 +25,7 @@
25 25  
26 26 - 优化`modal`与`drawer`滚动条组件
27 27 - table: 移除 `isTreeTable`属性
  28 +- 全局引入`less`文件。无需手动在组件再次引入
28 29  
29 30 ### 🎫 Chores
30 31  
... ... @@ -40,6 +41,7 @@
40 41 - 修复菜单分割时权限失效问题
41 42 - 关闭多标签页时 iframe 提前加载
42 43 - 修复`modal`与`drawer`已知问题
  44 +- 修复左侧菜单混合模式适配问题
43 45  
44 46 ## 2.0.0-rc.14 (2020-12-15)
45 47  
... ...
src/components/Menu/src/BasicMenu.vue
... ... @@ -110,7 +110,7 @@
110 110  
111 111 const inlineCollapseOptions: { inlineCollapsed?: boolean } = {};
112 112 if (isInline) {
113   - inlineCollapseOptions.inlineCollapsed = unref(getCollapsed);
  113 + inlineCollapseOptions.inlineCollapsed = props.mixSider ? false : unref(getCollapsed);
114 114 }
115 115 return inlineCollapseOptions;
116 116 });
... ...
src/components/Menu/src/props.ts
... ... @@ -17,12 +17,14 @@ export const basicProps = {
17 17 type: String as PropType<MenuModeEnum>,
18 18 default: MenuModeEnum.INLINE,
19 19 },
  20 +
20 21 type: {
21 22 type: String as PropType<MenuTypeEnum>,
22 23 default: MenuTypeEnum.MIX,
23 24 },
24 25 theme: propTypes.string.def(ThemeEnum.DARK),
25 26 inlineCollapsed: propTypes.bool,
  27 + mixSider: propTypes.bool,
26 28  
27 29 isHorizontal: propTypes.bool,
28 30 accordion: propTypes.bool.def(true),
... ...
src/components/Upload/src/data.tsx
... ... @@ -4,7 +4,7 @@ import { FileItem, PreviewFileItem, UploadResultStatus } from &#39;./types&#39;;
4 4 import { checkImgType, isImgTypeByName } from './helper';
5 5 import { Progress, Tag } from 'ant-design-vue';
6 6  
7   -import TableAction from '/@/components/Table/src/components/TableAction';
  7 +import TableAction from '/@/components/Table/src/components/TableAction.vue';
8 8 import ThumbUrl from './ThumbUrl.vue';
9 9 import { useI18n } from '/@/hooks/web/useI18n';
10 10 const { t } = useI18n();
... ...
src/layouts/default/sider/MixSider.vue
... ... @@ -54,6 +54,7 @@
54 54 mode="inline"
55 55 :items="chilrenMenus"
56 56 :theme="getMenuTheme"
  57 + mixSider
57 58 @menuClick="handleMenuClick"
58 59 />
59 60 </ScrollContainer>
... ...