mirror of
https://github.com/nagisa77/OpenIsle.git
synced 2026-02-26 16:10:49 +08:00
Compare commits
19 Commits
codex/crea
...
feature/av
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
425fc7d2b1 | ||
|
|
2b5f6f2208 | ||
|
|
bda377336d | ||
|
|
77507f7b18 | ||
|
|
a39f2f7c00 | ||
|
|
229439aa05 | ||
|
|
612881f1b1 | ||
|
|
05c7bc18d7 | ||
|
|
c68c5985f6 | ||
|
|
7d44791011 | ||
|
|
15b992b949 | ||
|
|
4b8229b0a1 | ||
|
|
6e4fbc3c42 | ||
|
|
779264623c | ||
|
|
a1eccb3b1e | ||
|
|
0f75a95dbe | ||
|
|
efbb83924b | ||
|
|
dc13b2941f | ||
|
|
13c250d392 |
@@ -108,7 +108,6 @@ body {
|
|||||||
|
|
||||||
.vditor-toolbar--pin {
|
.vditor-toolbar--pin {
|
||||||
top: calc(var(--header-height) + 1px) !important;
|
top: calc(var(--header-height) + 1px) !important;
|
||||||
z-index: 20;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.vditor-panel {
|
.vditor-panel {
|
||||||
@@ -134,26 +133,6 @@ body {
|
|||||||
animation: spin 1s linear infinite;
|
animation: spin 1s linear infinite;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* .vditor {
|
|
||||||
--textarea-background-color: transparent;
|
|
||||||
border: none !important;
|
|
||||||
box-shadow: none !important;
|
|
||||||
}
|
|
||||||
|
|
||||||
.vditor-reset {
|
|
||||||
color: var(--text-color);
|
|
||||||
}
|
|
||||||
|
|
||||||
.vditor-toolbar {
|
|
||||||
background: transparent !important;
|
|
||||||
border: none !important;
|
|
||||||
box-shadow: none !important;
|
|
||||||
} */
|
|
||||||
|
|
||||||
/* .vditor-toolbar {
|
|
||||||
position: relative !important;
|
|
||||||
} */
|
|
||||||
|
|
||||||
/*************************
|
/*************************
|
||||||
* Markdown 渲染样式
|
* Markdown 渲染样式
|
||||||
*************************/
|
*************************/
|
||||||
@@ -333,10 +312,6 @@ body {
|
|||||||
min-height: 100px;
|
min-height: 100px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.vditor-toolbar {
|
|
||||||
overflow-x: auto;
|
|
||||||
}
|
|
||||||
|
|
||||||
.about-content h1,
|
.about-content h1,
|
||||||
.info-content-text h1 {
|
.info-content-text h1 {
|
||||||
font-size: 20px;
|
font-size: 20px;
|
||||||
@@ -354,8 +329,8 @@ body {
|
|||||||
margin-bottom: 3px;
|
margin-bottom: 3px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.vditor-toolbar--pin {
|
.vditor-panel {
|
||||||
top: 0 !important;
|
min-width: 330px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.about-content li,
|
.about-content li,
|
||||||
@@ -367,11 +342,6 @@ body {
|
|||||||
line-height: 1.5;
|
line-height: 1.5;
|
||||||
}
|
}
|
||||||
|
|
||||||
.vditor-panel {
|
|
||||||
position: relative;
|
|
||||||
min-width: 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
.d2h-file-name {
|
.d2h-file-name {
|
||||||
font-size: 14px !important;
|
font-size: 14px !important;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,28 +1,19 @@
|
|||||||
<template>
|
<template>
|
||||||
<NuxtLink
|
<NuxtLink
|
||||||
v-if="isLink"
|
|
||||||
:to="resolvedLink"
|
:to="resolvedLink"
|
||||||
class="base-user-avatar"
|
class="base-user-avatar"
|
||||||
:class="wrapperClass"
|
:class="wrapperClass"
|
||||||
:style="wrapperStyle"
|
:style="wrapperStyle"
|
||||||
v-bind="wrapperAttrs"
|
v-bind="wrapperAttrs"
|
||||||
>
|
>
|
||||||
<img :src="currentSrc" :alt="altText" class="base-user-avatar-img" @error="onError" />
|
<BaseImage :src="currentSrc" :alt="altText" class="base-user-avatar-img" @error="onError" />
|
||||||
</NuxtLink>
|
</NuxtLink>
|
||||||
<div
|
|
||||||
v-else
|
|
||||||
class="base-user-avatar"
|
|
||||||
:class="wrapperClass"
|
|
||||||
:style="wrapperStyle"
|
|
||||||
v-bind="wrapperAttrs"
|
|
||||||
>
|
|
||||||
<img :src="currentSrc" :alt="altText" class="base-user-avatar-img" @error="onError" />
|
|
||||||
</div>
|
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script setup>
|
<script setup>
|
||||||
import { computed, ref, watch } from 'vue'
|
import { computed, ref, watch } from 'vue'
|
||||||
import { useAttrs } from 'vue'
|
import { useAttrs } from 'vue'
|
||||||
|
import BaseImage from './BaseImage.vue'
|
||||||
|
|
||||||
const DEFAULT_AVATAR = '/default-avatar.svg'
|
const DEFAULT_AVATAR = '/default-avatar.svg'
|
||||||
|
|
||||||
@@ -76,8 +67,6 @@ const resolvedLink = computed(() => {
|
|||||||
return null
|
return null
|
||||||
})
|
})
|
||||||
|
|
||||||
const isLink = computed(() => !props.disableLink && Boolean(resolvedLink.value))
|
|
||||||
|
|
||||||
const altText = computed(() => props.alt || '用户头像')
|
const altText = computed(() => props.alt || '用户头像')
|
||||||
|
|
||||||
const sizeStyle = computed(() => {
|
const sizeStyle = computed(() => {
|
||||||
@@ -113,6 +102,19 @@ function onError() {
|
|||||||
justify-content: center;
|
justify-content: center;
|
||||||
overflow: hidden;
|
overflow: hidden;
|
||||||
background-color: var(--avatar-placeholder-color, #f0f0f0);
|
background-color: var(--avatar-placeholder-color, #f0f0f0);
|
||||||
|
/* 先用box-sizing: border-box,保证加border后宽高不变,圆形不变形 */
|
||||||
|
box-sizing: border-box;
|
||||||
|
border: 1.5px solid var(--normal-border-color);
|
||||||
|
transition: all 0.6s ease;
|
||||||
|
}
|
||||||
|
|
||||||
|
.base-user-avatar:hover {
|
||||||
|
box-shadow: 0 4px 24px rgba(0, 0, 0, 0.1);
|
||||||
|
transform: scale(1.05);
|
||||||
|
}
|
||||||
|
|
||||||
|
.base-user-avatar:active {
|
||||||
|
box-shadow: 0 4px 24px rgba(0, 0, 0, 0.1);
|
||||||
}
|
}
|
||||||
|
|
||||||
.base-user-avatar.is-rounded {
|
.base-user-avatar.is-rounded {
|
||||||
|
|||||||
@@ -159,12 +159,6 @@ export default {
|
|||||||
border: 1px solid var(--border-color);
|
border: 1px solid var(--border-color);
|
||||||
border-radius: 8px;
|
border-radius: 8px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.vditor {
|
|
||||||
min-height: 50px;
|
|
||||||
max-height: 150px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.message-bottom-container {
|
.message-bottom-container {
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: row;
|
flex-direction: row;
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
<template>
|
<template>
|
||||||
<div class="user-list">
|
<div class="user-list">
|
||||||
<BasePlaceholder v-if="users.length === 0" text="暂无用户" icon="inbox" />
|
<BasePlaceholder v-if="users.length === 0" text="暂无用户" icon="inbox" />
|
||||||
<div v-for="u in users" :key="u.id" class="user-item" @click="handleUserClick(u)">
|
<div v-for="u in users" :key="u.id" class="user-item">
|
||||||
<BaseUserAvatar :src="u.avatar" :user-id="u.id" alt="avatar" class="user-avatar" />
|
<BaseUserAvatar :src="u.avatar" :user-id="u.id" alt="avatar" class="user-avatar" />
|
||||||
<div class="user-info">
|
<div class="user-info">
|
||||||
<div class="user-name">{{ u.username }}</div>
|
<div class="user-name">{{ u.username }}</div>
|
||||||
|
|||||||
@@ -85,20 +85,16 @@
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="article-member-avatars-container">
|
<div class="article-member-avatars-container">
|
||||||
<NuxtLink
|
<div v-for="member in article.members" class="article-member-avatar-item">
|
||||||
v-for="member in article.members"
|
|
||||||
:key="`${article.id}-${member.id}`"
|
|
||||||
class="article-member-avatar-item"
|
|
||||||
:to="`/users/${member.id}`"
|
|
||||||
>
|
|
||||||
<BaseUserAvatar
|
<BaseUserAvatar
|
||||||
class="article-member-avatar-item-img"
|
class="article-member-avatar-item-img"
|
||||||
:src="member.avatar"
|
:src="member.avatar"
|
||||||
:user-id="member.id"
|
:user-id="member.id"
|
||||||
alt="avatar"
|
alt="avatar"
|
||||||
:disable-link="true"
|
:disable-link="true"
|
||||||
|
:width="25"
|
||||||
/>
|
/>
|
||||||
</NuxtLink>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="article-comments main-info-text">
|
<div class="article-comments main-info-text">
|
||||||
@@ -634,13 +630,6 @@ watch([selectedCategory, selectedTags], ([newCategory, newTags]) => {
|
|||||||
margin-left: 20px;
|
margin-left: 20px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.article-member-avatar-item {
|
|
||||||
width: 25px;
|
|
||||||
height: 25px;
|
|
||||||
border-radius: 50%;
|
|
||||||
overflow: hidden;
|
|
||||||
}
|
|
||||||
|
|
||||||
.article-member-avatar-item-img {
|
.article-member-avatar-item-img {
|
||||||
width: 100%;
|
width: 100%;
|
||||||
height: 100%;
|
height: 100%;
|
||||||
@@ -703,6 +692,7 @@ watch([selectedCategory, selectedTags], ([newCategory, newTags]) => {
|
|||||||
margin-left: 0px;
|
margin-left: 0px;
|
||||||
gap: 0px;
|
gap: 0px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.article-main-container,
|
.article-main-container,
|
||||||
.header-item.main-item {
|
.header-item.main-item {
|
||||||
width: calc(70% - 20px);
|
width: calc(70% - 20px);
|
||||||
|
|||||||
Reference in New Issue
Block a user