mirror of
https://github.com/ChatGPTNextWeb/ChatGPT-Next-Web.git
synced 2025-10-01 15:46:39 +08:00
opt: adjust position of edit text
This commit is contained in:
parent
cc255eea3c
commit
568cd7d194
@ -252,9 +252,12 @@
|
|||||||
right: 10px;
|
right: 10px;
|
||||||
pointer-events: all;
|
pointer-events: all;
|
||||||
}
|
}
|
||||||
.chat-message-top-left-actions {
|
}
|
||||||
|
|
||||||
|
&:hover {
|
||||||
|
.chat-message-bottom-actions {
|
||||||
opacity: 1;
|
opacity: 1;
|
||||||
left:10px;
|
right: 10px;
|
||||||
pointer-events: all;
|
pointer-events: all;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -289,7 +292,6 @@
|
|||||||
.chat-message-item {
|
.chat-message-item {
|
||||||
box-sizing: border-box;
|
box-sizing: border-box;
|
||||||
max-width: 100%;
|
max-width: 100%;
|
||||||
min-width: 70px;
|
|
||||||
margin-top: 10px;
|
margin-top: 10px;
|
||||||
border-radius: 10px;
|
border-radius: 10px;
|
||||||
background-color: rgba(0, 0, 0, 0.05);
|
background-color: rgba(0, 0, 0, 0.05);
|
||||||
@ -330,10 +332,8 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
.chat-message-top-left-actions {
|
.chat-message-bottom-actions {
|
||||||
font-size: 12px;
|
font-size: 12px;
|
||||||
position: absolute;
|
|
||||||
top: -26px;
|
|
||||||
transition: all ease 0.3s;
|
transition: all ease 0.3s;
|
||||||
opacity: 0;
|
opacity: 0;
|
||||||
pointer-events: none;
|
pointer-events: none;
|
||||||
@ -341,7 +341,7 @@
|
|||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: row-reverse;
|
flex-direction: row-reverse;
|
||||||
|
|
||||||
.chat-message-top-left-action {
|
.chat-message-bottom-action {
|
||||||
opacity: 0.5;
|
opacity: 0.5;
|
||||||
color: var(--black);
|
color: var(--black);
|
||||||
white-space: nowrap;
|
white-space: nowrap;
|
||||||
@ -374,6 +374,13 @@
|
|||||||
color: #aaa;
|
color: #aaa;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.chat-message-action-edit {
|
||||||
|
opacity: 0.5;
|
||||||
|
color: var(--black);
|
||||||
|
white-space: nowrap;
|
||||||
|
cursor: pointer;
|
||||||
|
}
|
||||||
|
|
||||||
.chat-message-action-edit-button {
|
.chat-message-action-edit-button {
|
||||||
width: 24px;
|
width: 24px;
|
||||||
height: 15px;
|
height: 15px;
|
||||||
|
@ -467,16 +467,6 @@ export function Chat(props: {
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
)}
|
)}
|
||||||
{isUser && !message.preview && !message.isEditing && (
|
|
||||||
<div className={styles["chat-message-top-left-actions"]}>
|
|
||||||
<div
|
|
||||||
className={styles["chat-message-top-left-action"]}
|
|
||||||
onClick={() => onEdit(message)}>,
|
|
||||||
{Locale.Chat.Actions.Edit}
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
)
|
|
||||||
}
|
|
||||||
{(message.preview || message.content.length === 0) &&
|
{(message.preview || message.content.length === 0) &&
|
||||||
!isUser ? (
|
!isUser ? (
|
||||||
<LoadingIcon />
|
<LoadingIcon />
|
||||||
@ -503,6 +493,16 @@ export function Chat(props: {
|
|||||||
</div>
|
</div>
|
||||||
)}
|
)}
|
||||||
</div>
|
</div>
|
||||||
|
{isUser && !message.preview && !message.isEditing && (
|
||||||
|
<div className={styles["chat-message-bottom-actions"]}>
|
||||||
|
<div
|
||||||
|
className={styles["chat-message-bottom-action"]}
|
||||||
|
onClick={() => onEdit(message)}>
|
||||||
|
{Locale.Chat.Actions.Edit}
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
)
|
||||||
|
}
|
||||||
{!isUser && !message.preview && (
|
{!isUser && !message.preview && (
|
||||||
<div className={styles["chat-message-actions"]}>
|
<div className={styles["chat-message-actions"]}>
|
||||||
<div className={styles["chat-message-action-date"]}>
|
<div className={styles["chat-message-action-date"]}>
|
||||||
|
@ -86,7 +86,7 @@ const cn = {
|
|||||||
List: "自定义提示词列表",
|
List: "自定义提示词列表",
|
||||||
ListCount: (builtin: number, custom: number) =>
|
ListCount: (builtin: number, custom: number) =>
|
||||||
`内置 ${builtin} 条,用户定义 ${custom} 条`,
|
`内置 ${builtin} 条,用户定义 ${custom} 条`,
|
||||||
Edit: "编辑",
|
Edit: "编辑"
|
||||||
},
|
},
|
||||||
HistoryCount: {
|
HistoryCount: {
|
||||||
Title: "附带历史消息数",
|
Title: "附带历史消息数",
|
||||||
|
Loading…
Reference in New Issue
Block a user