mirror of
https://github.com/rowboatlabs/rowboat.git
synced 2026-07-21 21:31:12 +02:00
parent
b43dfaf14f
commit
63ed6e2dd6
4 changed files with 11 additions and 1 deletions
|
|
@ -1445,3 +1445,10 @@
|
||||||
transform: translateX(-120%);
|
transform: translateX(-120%);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* Issue #749: BiDi. unicode-bidi:plaintext resolves direction PER BLOCK from
|
||||||
|
its first strong character, so a message mixing English + RTL paragraphs
|
||||||
|
aligns each block correctly. text-align:start follows the resolved dir. */
|
||||||
|
.bidi-auto :is(p,h1,h2,h3,h4,h5,h6,li,blockquote,td,th){unicode-bidi:plaintext;text-align:start;}
|
||||||
|
/* Code is inherently LTR — keep it stable inside RTL messages. */
|
||||||
|
.bidi-auto :is(pre,code,kbd,samp){direction:ltr;unicode-bidi:isolate;text-align:left;}
|
||||||
|
|
|
||||||
|
|
@ -94,6 +94,7 @@ export const AskHumanRequest = ({
|
||||||
<div className="space-y-2">
|
<div className="space-y-2">
|
||||||
<Textarea
|
<Textarea
|
||||||
ref={textareaRef}
|
ref={textareaRef}
|
||||||
|
dir="auto"
|
||||||
value={response}
|
value={response}
|
||||||
onChange={(e) => setResponse(e.target.value)}
|
onChange={(e) => setResponse(e.target.value)}
|
||||||
onKeyDown={handleKeyDown}
|
onKeyDown={handleKeyDown}
|
||||||
|
|
|
||||||
|
|
@ -349,7 +349,7 @@ export const MessageResponse = memo(
|
||||||
({ className, ...props }: MessageResponseProps) => (
|
({ className, ...props }: MessageResponseProps) => (
|
||||||
<Streamdown
|
<Streamdown
|
||||||
className={cn(
|
className={cn(
|
||||||
"size-full [&>*:first-child]:mt-0 [&>*:last-child]:mb-0",
|
"size-full [&>*:first-child]:mt-0 [&>*:last-child]:mb-0 bidi-auto",
|
||||||
className
|
className
|
||||||
)}
|
)}
|
||||||
{...props}
|
{...props}
|
||||||
|
|
|
||||||
|
|
@ -1162,6 +1162,7 @@ export const PromptInputTextarea = ({
|
||||||
<div
|
<div
|
||||||
ref={highlightRef}
|
ref={highlightRef}
|
||||||
aria-hidden="true"
|
aria-hidden="true"
|
||||||
|
dir="auto"
|
||||||
className="pointer-events-none absolute inset-0 z-0 overflow-hidden whitespace-pre-wrap break-words text-sm text-transparent"
|
className="pointer-events-none absolute inset-0 z-0 overflow-hidden whitespace-pre-wrap break-words text-sm text-transparent"
|
||||||
>
|
>
|
||||||
{mentionHighlights.segments.map((segment, index) =>
|
{mentionHighlights.segments.map((segment, index) =>
|
||||||
|
|
@ -1180,6 +1181,7 @@ export const PromptInputTextarea = ({
|
||||||
)}
|
)}
|
||||||
<InputGroupTextarea
|
<InputGroupTextarea
|
||||||
ref={textareaRef}
|
ref={textareaRef}
|
||||||
|
dir="auto"
|
||||||
className={cn("relative z-10 !p-0 field-sizing-content max-h-48 min-h-10", className)}
|
className={cn("relative z-10 !p-0 field-sizing-content max-h-48 min-h-10", className)}
|
||||||
name="message"
|
name="message"
|
||||||
onCompositionEnd={() => setIsComposing(false)}
|
onCompositionEnd={() => setIsComposing(false)}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue