🌀(tag): update

This commit is contained in:
就眠儀式
2022-11-20 05:00:54 +08:00
parent 4021432a93
commit d96d718ac4
4 changed files with 16 additions and 16 deletions

View File

@@ -73,12 +73,8 @@
}
}
&-ellipsis &-text {
display: inline-block;
white-space: nowrap;
word-wrap: normal;
overflow: hidden;
text-overflow: ellipsis
& &-text {
overflow: hidden; text-overflow: ellipsis; white-space: nowrap
}
& &-close-icon {

View File

@@ -49,7 +49,6 @@ const classTag = computed(() => [
[`layui-tag-${props.type}`]: props.type,
"layui-tag-bordered": props.bordered,
"layui-tag-disabled": props.disabled,
"layui-tag-ellipsis": props.maxWidth,
},
]);
@@ -105,13 +104,8 @@ function useTagCustomStyle(props: TagProps) {
<span v-if="$slots.icon" class="layui-tag-icon">
<slot name="icon" />
</span>
<span
style="overflow: hidden; text-overflow: ellipsis; white-space: nowrap"
>
<span v-if="maxWidth" :style="styleTag" class="layui-tag-text">
<slot />
</span>
<slot v-else />
<span class="layui-tag-text">
<slot />
</span>
<span
v-if="closable"