fix develop mode style
This commit is contained in:
@@ -51,7 +51,7 @@ export default function Message(props: Props) {
|
||||
chat.role === "assistant" ? "justify-start" : "justify-end"
|
||||
}`}
|
||||
>
|
||||
<div className=" bg-">
|
||||
<div>
|
||||
<div
|
||||
className={`relative w-fit p-2 rounded my-2 ${
|
||||
chat.role === "assistant"
|
||||
@@ -59,28 +59,14 @@ export default function Message(props: Props) {
|
||||
: "bg-green-400"
|
||||
} ${chat.hide ? "opacity-50" : ""}`}
|
||||
>
|
||||
{chatStore.develop_mode ? (
|
||||
<textarea
|
||||
className="message-content"
|
||||
value={
|
||||
chat.hide
|
||||
? chat.content.split("\n")[0].slice(0, 16) + "... (deleted)"
|
||||
: chat.content
|
||||
}
|
||||
onChange={(event: any) => {
|
||||
chatStore.history[messageIndex].content = event.target.value;
|
||||
setChatStore({ ...chatStore });
|
||||
}}
|
||||
></textarea>
|
||||
) : (
|
||||
<p className="message-content">
|
||||
{chat.hide
|
||||
? chat.content.split("\n")[0].slice(0, 16) + "... (deleted)"
|
||||
: chat.content}
|
||||
</p>
|
||||
)}
|
||||
<DeleteIcon />
|
||||
</div>
|
||||
{chatStore.develop_mode && (
|
||||
<div>
|
||||
token {chatStore.history[messageIndex].token}
|
||||
<button
|
||||
@@ -104,6 +90,7 @@ export default function Message(props: Props) {
|
||||
❌
|
||||
</button>
|
||||
</div>
|
||||
)}
|
||||
</div>
|
||||
</div>
|
||||
</>
|
||||
|
||||
Reference in New Issue
Block a user