authorgravatar for 105376880+abdelrhmanehab10@users.noreply.github.comAbdelrhman Ehab <105376880+abdelrhmanehab10@users.noreply.github.com> 2026-10-11 06:13:08+03:00
committergravatar for noreply@github.comGitHub <noreply@github.com> 2026-10-11 03:13:08+00:00
logbfbdfed9826e3b619a99ba2b563608424c7cd807
tree6d9e4692bd4b87e3fd517fd80d835eafc962d587
parent584af5af4526fea4ad623c7bad931ef97d2fdb17
signature Signed by PGP key B5690EEEBB952194

fix(desktop): keep annotation comment direction independent of host page (#11005)

Co-authored-by: Claude Sonnet 5 <noreply@anthropic.com>

1 files changed, 3 insertions(+), 0 deletions(-)

apps/desktop/src/preview/PickPreload.ts+3
......@@ -554,6 +554,7 @@ function startAnnotation(sendEnabled: boolean): void {
554554 let finished = false;
555555 const host = document.createElement("div");
556556 host.setAttribute(OVERLAY_ATTRIBUTE, "");
557 host.setAttribute("dir", "ltr");
557558 host.style.cssText = `position:fixed;inset:0;z-index:${Z_INDEX_OVERLAY};pointer-events:none`;
558559 applyAnnotationTheme(host, annotationTheme);
559560 const shadowRoot = host.attachShadow({ mode: "closed" });
......@@ -563,6 +564,7 @@ function startAnnotation(sendEnabled: boolean): void {
563564
564565 const root = document.createElement("div");
565566 root.setAttribute(OVERLAY_ATTRIBUTE, "");
567 root.setAttribute("dir", "ltr");
566568 root.className = "fixed inset-0 font-sans text-foreground";
567569 root.style.cssText = "pointer-events:none";
568570 const cursorStyle = document.createElement("style");
......@@ -612,6 +614,7 @@ function startAnnotation(sendEnabled: boolean): void {
612614
613615 const comment = document.createElement("textarea");
614616 comment.placeholder = "Describe the change…";
617 comment.setAttribute("dir", "auto");
615618 comment.rows = 1;
616619 comment.className =
617620 "min-h-8 max-h-24 min-w-0 flex-1 resize-none overflow-y-hidden border-0 border-b border-b-transparent bg-transparent px-0 py-1.5 font-sans text-sm leading-5 text-foreground outline-none ring-0 placeholder:text-muted-foreground focus:border-b-primary focus:outline-none focus:ring-0";