🌀(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"

View File

@ -14,7 +14,7 @@
<template>
<lay-space size="md">
<lay-tag>标签</lay-tag>
<lay-tag maxWidth="100px">标签</lay-tag>
<lay-tag v-for="type in TAG_TYPES" :type="type">标签</lay-tag>
</lay-space>
</template>
@ -164,6 +164,7 @@ export default {
<template v-for="(tag, index) of tagData" :key="`tag-${index}`">
<lay-tag
closable
maxWidth="100px"
@close="handleClose(index)"
style="margin-right: 5px;"
>

View File

@ -11,6 +11,15 @@
<template>
<lay-timeline>
<lay-timeline-item title="1.7.x">
<ul>
<a name="1-7-9"></a>
<li>
<h3>1.7.9 <span class="layui-badge-rim">2022-11-20</span></h3>
<ul>
<li>[新增] upload 组件 auto 属性, 是否自动上传配置。</li>
</ul>
</li>
</ul>
<ul>
<a name="1-7-8"></a>
<li>