fix: 修复三级菜单向左折叠后图标显示样式问题

This commit is contained in:
xiaoxian521 2024-04-15 16:25:01 +08:00
parent ea36e260e2
commit dbb05f4166

View File

@ -145,7 +145,7 @@ function resolvePath(routePath) {
props.item?.pathList?.length === 2) props.item?.pathList?.length === 2)
" "
truncated truncated
class="!px-4 !text-inherit" class="!w-full !px-4 !text-inherit"
> >
{{ transformI18n(onlyOneChild.meta.title) }} {{ transformI18n(onlyOneChild.meta.title) }}
</el-text> </el-text>
@ -157,7 +157,7 @@ function resolvePath(routePath) {
offset: [0, -10], offset: [0, -10],
theme: tooltipEffect theme: tooltipEffect
}" }"
class="!text-inherit" class="!w-full !text-inherit"
> >
{{ transformI18n(onlyOneChild.meta.title) }} {{ transformI18n(onlyOneChild.meta.title) }}
</ReText> </ReText>
@ -185,7 +185,9 @@ function resolvePath(routePath) {
</div> </div>
<ReText <ReText
v-if=" v-if="
!( layout === 'mix' && toRaw(props.item.meta.icon)
? !isCollapse || props.item?.pathList?.length !== 2
: !(
layout === 'vertical' && layout === 'vertical' &&
isCollapse && isCollapse &&
toRaw(props.item.meta.icon) && toRaw(props.item.meta.icon) &&
@ -197,6 +199,7 @@ function resolvePath(routePath) {
theme: tooltipEffect theme: tooltipEffect
}" }"
:class="{ :class="{
'!w-full': true,
'!text-inherit': true, '!text-inherit': true,
'!px-4': '!px-4':
layout !== 'horizontal' && layout !== 'horizontal' &&