feat ui设计稿
This commit is contained in:
@@ -41,10 +41,10 @@ const emojiMap: Record<MessageType, string> = {
|
||||
|
||||
<style lang="less" scoped>
|
||||
.message-item {
|
||||
position: relative; // 未读徽标相对行定位(压图标右上角)
|
||||
.flex(row, flex-start);
|
||||
gap: @spacing-base;
|
||||
padding: @spacing-base;
|
||||
border-radius: @radius-base;
|
||||
gap: @spacing-base; // 图标→标题 22 × 0.77
|
||||
padding: 14px 17px; // 行内边距 23/22 × 0.77
|
||||
background: @white;
|
||||
cursor: pointer;
|
||||
transition: background 0.2s;
|
||||
@@ -53,17 +53,24 @@ const emojiMap: Record<MessageType, string> = {
|
||||
background: @bg-color-light;
|
||||
}
|
||||
|
||||
// 类型图标圆:设计 43 直径 40 × 0.77,实取 #3B82F6
|
||||
&__emoji {
|
||||
flex-shrink: 0;
|
||||
font-size: @font-size-xl;
|
||||
line-height: 1.4;
|
||||
.flex(row, center);
|
||||
width: 31px;
|
||||
height: 31px;
|
||||
border-radius: @radius-round;
|
||||
background: @message-icon-bg;
|
||||
font-size: 15px;
|
||||
line-height: 1;
|
||||
}
|
||||
|
||||
&__body {
|
||||
.flex(column, flex-start);
|
||||
gap: @spacing-xs;
|
||||
.flex(column, flex-start, stretch);
|
||||
gap: 5px; // 标题→摘要 6 × 0.77
|
||||
flex: 1;
|
||||
min-width: 0;
|
||||
margin-top: 6px; // 标题比图标顶下移 9 × 0.77
|
||||
}
|
||||
|
||||
&__head {
|
||||
@@ -72,27 +79,33 @@ const emojiMap: Record<MessageType, string> = {
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
// 设计 43:标题 14 → 可读下限 11 / 600 / #1F2937(所有行均半粗)
|
||||
&__title {
|
||||
font-size: @font-size-lg;
|
||||
font-size: 11px;
|
||||
font-weight: 600;
|
||||
color: @heading-color;
|
||||
.ellipsis();
|
||||
}
|
||||
|
||||
&__time {
|
||||
flex-shrink: 0;
|
||||
font-size: @font-size-sm;
|
||||
font-size: 11px; // 设计 12 → 可读下限 11
|
||||
color: @text-color-disabled; // 设计 43 时间 @text-color-disabled(覆盖 text-secondary)
|
||||
}
|
||||
|
||||
// 设计 43:摘要 12 → 可读下限 11 / #6B7280(text-secondary)
|
||||
&__summary {
|
||||
font-size: @font-size-base;
|
||||
font-size: 11px;
|
||||
.ellipsis();
|
||||
}
|
||||
|
||||
// 未读徽标:设计 43 红圆压图标右上(≈ 直径 20 × 0.77)
|
||||
&__dot {
|
||||
flex-shrink: 0;
|
||||
align-self: center;
|
||||
width: 8px;
|
||||
height: 8px;
|
||||
position: absolute;
|
||||
top: 12px;
|
||||
left: 42px;
|
||||
width: 15px;
|
||||
height: 15px;
|
||||
border-radius: @radius-round;
|
||||
background: @danger-color;
|
||||
}
|
||||
|
||||
@@ -29,16 +29,22 @@ const emit = defineEmits<{ view: [id: string] }>()
|
||||
|
||||
<style lang="less" scoped>
|
||||
.message-list {
|
||||
.flex(column, flex-start);
|
||||
gap: @spacing-sm;
|
||||
padding: @spacing-sm;
|
||||
border-radius: @radius-lg;
|
||||
background: @bg-color;
|
||||
.flex(column, flex-start, stretch);
|
||||
gap: 0; // 行紧排,行间以分割线分隔(设计 43)
|
||||
padding: 0;
|
||||
border-radius: @radius-base;
|
||||
background: @white; // 设计 43 列表卡白底直压页面灰底
|
||||
overflow: hidden; // 悬停底色收敛在卡圆角内
|
||||
|
||||
// 行分割线:设计 43 实取 #F0F1F3(矩形 1/2,跨满卡内容宽)
|
||||
.message-item + .message-item {
|
||||
border-top: 1px solid @project-divider;
|
||||
}
|
||||
|
||||
&__empty {
|
||||
padding: @spacing-xxl 0;
|
||||
padding: 40px 0;
|
||||
text-align: center;
|
||||
font-size: @font-size-base;
|
||||
font-size: 11px; // 设计 43 空态文字 → 可读下限 11
|
||||
}
|
||||
}
|
||||
</style>
|
||||
|
||||
@@ -46,50 +46,52 @@ function countOf(value: MessageType | 'all', counts: Counts): number {
|
||||
|
||||
<style lang="less" scoped>
|
||||
.message-tabs {
|
||||
.flex(row, flex-start);
|
||||
gap: @spacing-sm;
|
||||
padding: @spacing-sm @spacing-base;
|
||||
border-radius: @radius-lg;
|
||||
.flex(column, flex-start, stretch);
|
||||
padding: 18px 0; // 卡上内边距 24 × 0.77
|
||||
min-height: 338px; // 设计左卡高 439 × 0.77
|
||||
border-radius: @radius-base;
|
||||
background: @white;
|
||||
box-shadow: @shadow-base;
|
||||
box-shadow: none; // 设计 43:白卡直压页面底色,无阴影无描边
|
||||
|
||||
&__tab {
|
||||
.flex(row, center);
|
||||
gap: @spacing-xs;
|
||||
height: 32px;
|
||||
padding: 0 @spacing-base;
|
||||
border-radius: @radius-round;
|
||||
.flex(row, space-between);
|
||||
gap: @spacing-sm;
|
||||
height: 32px; // 分类行间距 41 × 0.77
|
||||
padding: 0 18px 0 25px; // 左 33 / 右 23 × 0.77
|
||||
border-radius: 0;
|
||||
background: transparent;
|
||||
color: @text-color;
|
||||
font-size: @font-size-base;
|
||||
color: @text-color; // 设计 43 未选中 @text-color
|
||||
font-size: 11px; // 设计 13 → 可读下限 11
|
||||
font-weight: 400;
|
||||
transition: all 0.2s;
|
||||
|
||||
&:hover {
|
||||
color: @primary-color;
|
||||
color: @primary-strong;
|
||||
}
|
||||
|
||||
&.is-active {
|
||||
background: @primary-light;
|
||||
color: @primary-color;
|
||||
background: transparent; // 设计 43 选中无胶囊底
|
||||
color: @primary-strong; // 设计 43 选中 @primary-strong
|
||||
font-weight: 600;
|
||||
}
|
||||
}
|
||||
|
||||
&__count {
|
||||
min-width: 18px;
|
||||
height: 18px;
|
||||
padding: 0 5px;
|
||||
min-width: 15px; // 徽标直径 20 × 0.77
|
||||
height: 15px;
|
||||
padding: 0 4px;
|
||||
border-radius: @radius-round;
|
||||
background: @bg-color;
|
||||
color: @text-color-secondary;
|
||||
font-size: @font-size-sm;
|
||||
line-height: 18px;
|
||||
background: @danger-color; // 设计 43 红底 ≈ #F54343
|
||||
color: @white;
|
||||
font-size: 11px; // 设计 10 → 可读下限 11
|
||||
line-height: 15px;
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
.is-active &__count {
|
||||
background: @primary-color;
|
||||
background: @danger-color; // 设计 43 选中项徽标仍为红底
|
||||
color: @white;
|
||||
font-weight: 600;
|
||||
}
|
||||
}
|
||||
</style>
|
||||
|
||||
Reference in New Issue
Block a user