Skip to content

Commit

Permalink
fix: Fix the loss of layout style and scrolling anomaly
Browse files Browse the repository at this point in the history
  • Loading branch information
Amery2010 committed Jan 26, 2025
1 parent 94d74c6 commit 7cc2499
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 2 deletions.
19 changes: 18 additions & 1 deletion app/globals.css
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,24 @@ body {
width: 20px;
height: 20px;
}

.text-line-clamp-2 {
display: -webkit-box;
-webkit-line-clamp: 2;
line-clamp: 2;
-webkit-box-orient: vertical;
box-orient: vertical;
overflow: hidden;
text-overflow: ellipsis;
}
.text-line-clamp-3 {
display: -webkit-box;
-webkit-line-clamp: 3;
line-clamp: 3;
-webkit-box-orient: vertical;
box-orient: vertical;
overflow: hidden;
text-overflow: ellipsis;
}
.chat-content img {
width: 100%;
max-width: 500px;
Expand Down
2 changes: 1 addition & 1 deletion app/page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -1004,7 +1004,7 @@ export default function Home() {
onChange={(ev) => {
setContent(ev.target.value)
setTextareaHeight(ev.target.value === '' ? TEXTAREA_DEFAULT_HEIGHT : ev.target.scrollHeight)
scrollToBottom()
if (messages.length > 1) scrollToBottom()
}}
onKeyDown={handleKeyDown}
/>
Expand Down

0 comments on commit 7cc2499

Please sign in to comment.