Skip to content

Commit 5cdfed5

Browse files
author
preschooler
committed
🐞 fix:修复标签栏高度(被box-sizing和scrollbar__view的height: 99%干扰)
1 parent 323e619 commit 5cdfed5

File tree

1 file changed

+10
-8
lines changed

1 file changed

+10
-8
lines changed

src/layout/components/TagsView/src/TagsView.vue

Lines changed: 10 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -280,7 +280,7 @@ watch(
280280
</span>
281281
<div class="flex-1 overflow-hidden">
282282
<ElScrollbar ref="scrollbarRef" class="h-full" @scroll="scroll">
283-
<div class="h-full flex">
283+
<div class="h-[var(--tags-view-height)] flex">
284284
<ContextMenu
285285
:ref="itemRefs.set"
286286
:schema="[
@@ -491,21 +491,21 @@ $prefix-cls: #{$namespace}-tags-view;
491491
492492
&::before {
493493
position: absolute;
494-
top: 1px;
494+
top: 0;
495495
left: 0;
496496
width: 100%;
497-
height: calc(100% - 1px);
497+
height: 100%;
498498
border-left: 1px solid var(--el-border-color);
499499
content: '';
500500
}
501501
502502
&--first {
503503
&::before {
504504
position: absolute;
505-
top: 1px;
505+
top: 0;
506506
left: 0;
507507
width: 100%;
508-
height: calc(100% - 1px);
508+
height: 100%;
509509
border-right: 1px solid var(--el-border-color);
510510
border-left: none;
511511
content: '';
@@ -515,14 +515,15 @@ $prefix-cls: #{$namespace}-tags-view;
515515
516516
&__item {
517517
position: relative;
518-
top: 2px;
518+
top: 3px;
519519
height: calc(100% - 6px);
520520
padding-right: 15px;
521521
margin-left: 4px;
522522
font-size: 12px;
523523
cursor: pointer;
524524
border: 1px solid #d9d9d9;
525525
border-radius: 2px;
526+
box-sizing: border-box;
526527
527528
&--close {
528529
position: absolute;
@@ -560,10 +561,11 @@ $prefix-cls: #{$namespace}-tags-view;
560561
}
561562
562563
&__item--immerse {
563-
top: 3px;
564+
top: 2px;
565+
height: calc(100% - 3px);
564566
padding-right: 35px;
565567
margin: 0 -10px;
566-
border: 1px solid transparent;
568+
border: none !important;
567569
-webkit-mask-box-image: url("data:image/svg+xml,%3Csvg width='68' height='34' viewBox='0 0 68 34' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath fill-rule='evenodd' clip-rule='evenodd' d='m27,0c-7.99582,0 -11.95105,0.00205 -12,12l0,6c0,8.284 -0.48549,16.49691 -8.76949,16.49691l54.37857,-0.11145c-8.284,0 -8.60908,-8.10146 -8.60908,-16.38546l0,-6c0.11145,-12.08445 -4.38441,-12 -12,-12l-13,0z' fill='%23409eff'/%3E%3C/svg%3E")
568570
12 27 15;
569571
.#{$prefix-cls}__item--label {

0 commit comments

Comments
 (0)