word wrap fix

This commit is contained in:
ajaythapliyal
2023-02-26 20:04:55 +05:30
parent 2348848c18
commit b4a4007f66
2 changed files with 2 additions and 2 deletions

View File

@@ -49,7 +49,7 @@ export default function Conversation() {
<div
ref={inputRef}
contentEditable
className={`border-000000 overflow-x-hidden; max-h-24 min-h-[2.6rem] w-full overflow-y-auto whitespace-pre-wrap rounded-xl border bg-white p-2 pr-9 leading-7 opacity-100 focus:outline-none`}
className={`border-000000 overflow-x-hidden; max-h-24 min-h-[2.6rem] w-full overflow-y-auto whitespace-pre-wrap rounded-xl border bg-white py-2 pl-4 pr-9 leading-7 opacity-100 focus:outline-none`}
onKeyDown={(e) => {
if (e.key === 'Enter' && !e.shiftKey) {
e.preventDefault();

View File

@@ -35,7 +35,7 @@ const ConversationBubble = forwardRef<
{type === 'ERROR' && (
<img src={Alert} alt="alert" className="mr-2 inline" />
)}
<p className="whitespace-pre-wrap break-all">{message}</p>
<p className="whitespace-pre-wrap break-words">{message}</p>
</div>
</div>
);