Skip to content

Commit 0e0661f

Browse files
authored
fix: breadcrumb style is affected by the globally-imported antd styles (#5627)
* 修复全局引入Antd时,面包屑的样式会受到影响的问题
1 parent 86ce65e commit 0e0661f

File tree

1 file changed

+19
-2
lines changed

1 file changed

+19
-2
lines changed

packages/@core/ui-kit/shadcn-ui/src/components/breadcrumb/breadcrumb-view.vue

Lines changed: 19 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,23 @@ const emit = defineEmits<{ select: [string] }>();
1717
const forward = useForwardPropsEmits(props, emit);
1818
</script>
1919
<template>
20-
<Breadcrumb v-if="styleType === 'normal'" v-bind="forward" />
21-
<BreadcrumbBackground v-if="styleType === 'background'" v-bind="forward" />
20+
<Breadcrumb
21+
v-if="styleType === 'normal'"
22+
v-bind="forward"
23+
class="vben-breadcrumb"
24+
/>
25+
<BreadcrumbBackground
26+
v-if="styleType === 'background'"
27+
v-bind="forward"
28+
class="vben-breadcrumb"
29+
/>
2230
</template>
31+
<style lang="scss" scoped>
32+
/** 修复全局引入Antd时,ol和ul的默认样式会被修改的问题 */
33+
.vben-breadcrumb {
34+
:deep(ol),
35+
:deep(ul) {
36+
margin-bottom: 0;
37+
}
38+
}
39+
</style>

0 commit comments

Comments
 (0)