react-grab 0.0.69 → 0.0.71

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -888,7 +888,7 @@ function cleanChildren(parent, current, marker, replacement) {
888
888
 
889
889
  // dist/styles.css
890
890
  var styles_default = `/*! tailwindcss v4.1.17 | MIT License | https://tailwindcss.com */
891
- @layer properties{@supports (((-webkit-hyphens:none)) and (not (margin-trim:inline))) or ((-moz-orient:inline) and (not (color:rgb(from red r g b)))){*,:before,:after,::backdrop{--tw-translate-x:0;--tw-translate-y:0;--tw-translate-z:0;--tw-scale-x:1;--tw-scale-y:1;--tw-scale-z:1;--tw-rotate-x:initial;--tw-rotate-y:initial;--tw-rotate-z:initial;--tw-skew-x:initial;--tw-skew-y:initial;--tw-border-style:solid;--tw-leading:initial;--tw-font-weight:initial;--tw-tracking:initial;--tw-ordinal:initial;--tw-slashed-zero:initial;--tw-numeric-figure:initial;--tw-numeric-spacing:initial;--tw-numeric-fraction:initial;--tw-blur:initial;--tw-brightness:initial;--tw-contrast:initial;--tw-grayscale:initial;--tw-hue-rotate:initial;--tw-invert:initial;--tw-opacity:initial;--tw-saturate:initial;--tw-sepia:initial;--tw-drop-shadow:initial;--tw-drop-shadow-color:initial;--tw-drop-shadow-alpha:100%;--tw-drop-shadow-size:initial;--tw-duration:initial;--tw-ease:initial;--tw-contain-size:initial;--tw-contain-layout:initial;--tw-contain-paint:initial;--tw-contain-style:initial}}}@layer theme{:root,:host{--font-sans:ui-sans-serif,system-ui,sans-serif,"Apple Color Emoji","Segoe UI Emoji","Segoe UI Symbol","Noto Color Emoji";--font-mono:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,"Liberation Mono","Courier New",monospace;--color-black:#000;--color-white:#fff;--spacing:.25rem;--font-weight-medium:500;--radius-xs:.125rem;--ease-out:cubic-bezier(0,0,.2,1);--animate-pulse:pulse 2s cubic-bezier(.4,0,.6,1)infinite;--default-transition-duration:.15s;--default-transition-timing-function:cubic-bezier(.4,0,.2,1);--default-font-family:var(--font-sans);--default-mono-font-family:var(--font-mono);--color-grab-pink:#b21c8e;--color-grab-purple:#d239c0;--color-label-tag-border:#730079;--color-label-muted:#767676}}@layer base{*,:after,:before,::backdrop{box-sizing:border-box;border:0 solid;margin:0;padding:0}::file-selector-button{box-sizing:border-box;border:0 solid;margin:0;padding:0}html,:host{-webkit-text-size-adjust:100%;tab-size:4;line-height:1.5;font-family:var(--default-font-family,ui-sans-serif,system-ui,sans-serif,"Apple Color Emoji","Segoe UI Emoji","Segoe UI Symbol","Noto Color Emoji");font-feature-settings:var(--default-font-feature-settings,normal);font-variation-settings:var(--default-font-variation-settings,normal);-webkit-tap-highlight-color:transparent}hr{height:0;color:inherit;border-top-width:1px}abbr:where([title]){-webkit-text-decoration:underline dotted;text-decoration:underline dotted}h1,h2,h3,h4,h5,h6{font-size:inherit;font-weight:inherit}a{color:inherit;-webkit-text-decoration:inherit;-webkit-text-decoration:inherit;-webkit-text-decoration:inherit;text-decoration:inherit}b,strong{font-weight:bolder}code,kbd,samp,pre{font-family:var(--default-mono-font-family,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,"Liberation Mono","Courier New",monospace);font-feature-settings:var(--default-mono-font-feature-settings,normal);font-variation-settings:var(--default-mono-font-variation-settings,normal);font-size:1em}small{font-size:80%}sub,sup{vertical-align:baseline;font-size:75%;line-height:0;position:relative}sub{bottom:-.25em}sup{top:-.5em}table{text-indent:0;border-color:inherit;border-collapse:collapse}:-moz-focusring{outline:auto}progress{vertical-align:baseline}summary{display:list-item}ol,ul,menu{list-style:none}img,svg,video,canvas,audio,iframe,embed,object{vertical-align:middle;display:block}img,video{max-width:100%;height:auto}button,input,select,optgroup,textarea{font:inherit;font-feature-settings:inherit;font-variation-settings:inherit;letter-spacing:inherit;color:inherit;opacity:1;background-color:#0000;border-radius:0}::file-selector-button{font:inherit;font-feature-settings:inherit;font-variation-settings:inherit;letter-spacing:inherit;color:inherit;opacity:1;background-color:#0000;border-radius:0}:where(select:is([multiple],[size])) optgroup{font-weight:bolder}:where(select:is([multiple],[size])) optgroup option{padding-inline-start:20px}::file-selector-button{margin-inline-end:4px}::placeholder{opacity:1}@supports (not ((-webkit-appearance:-apple-pay-button))) or (contain-intrinsic-size:1px){::placeholder{color:currentColor}@supports (color:color-mix(in lab, red, red)){::placeholder{color:color-mix(in oklab,currentcolor 50%,transparent)}}}textarea{resize:vertical}::-webkit-search-decoration{-webkit-appearance:none}::-webkit-date-and-time-value{min-height:1lh;text-align:inherit}::-webkit-datetime-edit{display:inline-flex}::-webkit-datetime-edit-fields-wrapper{padding:0}::-webkit-datetime-edit{padding-block:0}::-webkit-datetime-edit-year-field{padding-block:0}::-webkit-datetime-edit-month-field{padding-block:0}::-webkit-datetime-edit-day-field{padding-block:0}::-webkit-datetime-edit-hour-field{padding-block:0}::-webkit-datetime-edit-minute-field{padding-block:0}::-webkit-datetime-edit-second-field{padding-block:0}::-webkit-datetime-edit-millisecond-field{padding-block:0}::-webkit-datetime-edit-meridiem-field{padding-block:0}::-webkit-calendar-picker-indicator{line-height:1}:-moz-ui-invalid{box-shadow:none}button,input:where([type=button],[type=reset],[type=submit]){appearance:button}::file-selector-button{appearance:button}::-webkit-inner-spin-button{height:auto}::-webkit-outer-spin-button{height:auto}[hidden]:where(:not([hidden=until-found])){display:none!important}}@layer components;@layer utilities{.pointer-events-auto{pointer-events:auto}.pointer-events-none{pointer-events:none}.visible{visibility:visible}.absolute{position:absolute}.fixed{position:fixed}.top-0{top:calc(var(--spacing)*0)}.left-0{left:calc(var(--spacing)*0)}.z-2147483645{z-index:2147483645}.z-2147483646{z-index:2147483646}.z-2147483647{z-index:2147483647}.z-\\[2147483645\\]{z-index:2147483645}.container{width:100%}@media (min-width:40rem){.container{max-width:40rem}}@media (min-width:48rem){.container{max-width:48rem}}@media (min-width:64rem){.container{max-width:64rem}}@media (min-width:80rem){.container{max-width:80rem}}@media (min-width:96rem){.container{max-width:96rem}}.m-0{margin:calc(var(--spacing)*0)}.-ml-\\[2px\\]{margin-left:-2px}.ml-1{margin-left:calc(var(--spacing)*1)}.box-border{box-sizing:border-box}.flex{display:flex}.grid{display:grid}.hidden{display:none}.size-fit{width:fit-content;height:fit-content}.h-0{height:calc(var(--spacing)*0)}.h-4{height:calc(var(--spacing)*4)}.h-5{height:calc(var(--spacing)*5)}.h-5\\.5{height:calc(var(--spacing)*5.5)}.h-\\[7px\\]{height:7px}.h-\\[9px\\]{height:9px}.h-\\[18px\\]{height:18px}.h-fit{height:fit-content}.min-h-0{min-height:calc(var(--spacing)*0)}.min-h-4{min-height:calc(var(--spacing)*4)}.w-0{width:calc(var(--spacing)*0)}.w-0\\.5{width:calc(var(--spacing)*.5)}.w-1{width:calc(var(--spacing)*1)}.w-2\\.5{width:calc(var(--spacing)*2.5)}.w-\\[7px\\]{width:7px}.w-auto{width:auto}.w-fit{width:fit-content}.w-full{width:100%}.max-w-\\[280px\\]{max-width:280px}.flex-1{flex:1}.shrink{flex-shrink:1}.shrink-0{flex-shrink:0}.-translate-x-1\\/2{--tw-translate-x:calc(calc(1/2*100%)*-1);translate:var(--tw-translate-x)var(--tw-translate-y)}.-translate-y-1\\/2{--tw-translate-y:calc(calc(1/2*100%)*-1);translate:var(--tw-translate-x)var(--tw-translate-y)}.scale-75{--tw-scale-x:75%;--tw-scale-y:75%;--tw-scale-z:75%;scale:var(--tw-scale-x)var(--tw-scale-y)}.scale-100{--tw-scale-x:100%;--tw-scale-y:100%;--tw-scale-z:100%;scale:var(--tw-scale-x)var(--tw-scale-y)}.transform{transform:var(--tw-rotate-x,)var(--tw-rotate-y,)var(--tw-rotate-z,)var(--tw-skew-x,)var(--tw-skew-y,)}.animate-pulse{animation:var(--animate-pulse)}.cursor-crosshair{cursor:crosshair}.cursor-pointer{cursor:pointer}.resize{resize:both}.resize-none{resize:none}.flex-col{flex-direction:column}.items-center{align-items:center}.items-end{align-items:flex-end}.items-start{align-items:flex-start}.justify-between{justify-content:space-between}.justify-center{justify-content:center}.gap-0\\.5{gap:calc(var(--spacing)*.5)}.gap-1{gap:calc(var(--spacing)*1)}.gap-\\[3px\\]{gap:3px}.gap-\\[5px\\]{gap:5px}.gap-px{gap:1px}.self-stretch{align-self:stretch}.overflow-hidden{overflow:hidden}.rounded-\\[1\\.5px\\]{border-radius:1.5px}.rounded-\\[1px\\]{border-radius:1px}.rounded-full{border-radius:3.40282e38px}.rounded-xs{border-radius:var(--radius-xs)}.rounded-t-none{border-top-left-radius:0;border-top-right-radius:0}.rounded-b-xs{border-bottom-right-radius:var(--radius-xs);border-bottom-left-radius:var(--radius-xs)}.border{border-style:var(--tw-border-style);border-width:1px}.\\[border-width\\:0\\.5px\\]{border-width:.5px}.\\[border-top-width\\:0\\.5px\\]{border-top-width:.5px}.border-none{--tw-border-style:none;border-style:none}.border-solid{--tw-border-style:solid;border-style:solid}.border-\\[\\#B3B3B3\\]{border-color:#b3b3b3}.border-grab-purple{border-color:var(--color-grab-purple)}.border-grab-purple\\/40{border-color:#d239c066}@supports (color:color-mix(in lab, red, red)){.border-grab-purple\\/40{border-color:color-mix(in oklab,var(--color-grab-purple)40%,transparent)}}.border-grab-purple\\/50{border-color:#d239c080}@supports (color:color-mix(in lab, red, red)){.border-grab-purple\\/50{border-color:color-mix(in oklab,var(--color-grab-purple)50%,transparent)}}.border-label-tag-border{border-color:var(--color-label-tag-border)}.border-white{border-color:var(--color-white)}.border-t-\\[\\#D9D9D9\\]{border-top-color:#d9d9d9}.bg-\\[\\#F7F7F7\\]{background-color:#f7f7f7}.bg-black{background-color:var(--color-black)}.bg-grab-pink{background-color:var(--color-grab-pink)}.bg-grab-purple{background-color:var(--color-grab-purple)}.bg-grab-purple\\/5{background-color:#d239c00d}@supports (color:color-mix(in lab, red, red)){.bg-grab-purple\\/5{background-color:color-mix(in oklab,var(--color-grab-purple)5%,transparent)}}.bg-grab-purple\\/8{background-color:#d239c014}@supports (color:color-mix(in lab, red, red)){.bg-grab-purple\\/8{background-color:color-mix(in oklab,var(--color-grab-purple)8%,transparent)}}.bg-transparent{background-color:#0000}.bg-white{background-color:var(--color-white)}.bg-cover{background-size:cover}.bg-center{background-position:50%}.p-0{padding:calc(var(--spacing)*0)}.p-1{padding:calc(var(--spacing)*1)}.px-0{padding-inline:calc(var(--spacing)*0)}.px-1\\.5{padding-inline:calc(var(--spacing)*1.5)}.px-2{padding-inline:calc(var(--spacing)*2)}.px-\\[3px\\]{padding-inline:3px}.py-0{padding-block:calc(var(--spacing)*0)}.py-1{padding-block:calc(var(--spacing)*1)}.py-\\[3px\\]{padding-block:3px}.py-\\[5px\\]{padding-block:5px}.py-px{padding-block:1px}.pt-1{padding-top:calc(var(--spacing)*1)}.align-middle{vertical-align:middle}.font-\\[ui-monospace\\,\\'SFMono-Regular\\'\\,\\'SF_Mono\\'\\,\\'Menlo\\'\\,\\'Consolas\\'\\,\\'Liberation_Mono\\'\\,monospace\\]{font-family:ui-monospace,SFMono-Regular,SF Mono,Menlo,Consolas,Liberation Mono,monospace}.font-mono{font-family:var(--font-mono)}.font-sans{font-family:var(--font-sans)}.text-\\[11\\.5px\\]{font-size:11.5px}.text-\\[12px\\]{font-size:12px}.leading-3\\.5{--tw-leading:calc(var(--spacing)*3.5);line-height:calc(var(--spacing)*3.5)}.leading-4{--tw-leading:calc(var(--spacing)*4);line-height:calc(var(--spacing)*4)}.font-medium{--tw-font-weight:var(--font-weight-medium);font-weight:var(--font-weight-medium)}.tracking-\\[-0\\.04em\\]{--tw-tracking:-.04em;letter-spacing:-.04em}.tracking-\\[-0\\.08em\\]{--tw-tracking:-.08em;letter-spacing:-.08em}.break-all{word-break:break-all}.whitespace-normal{white-space:normal}.text-\\[\\#0C0C0C\\]{color:#0c0c0c}.text-\\[\\#47004A\\]{color:#47004a}.text-black{color:var(--color-black)}.text-black\\/50{color:#00000080}@supports (color:color-mix(in lab, red, red)){.text-black\\/50{color:color-mix(in oklab,var(--color-black)50%,transparent)}}.text-label-muted{color:var(--color-label-muted)}.text-label-tag-border{color:var(--color-label-tag-border)}.text-white{color:var(--color-white)}.tabular-nums{--tw-numeric-spacing:tabular-nums;font-variant-numeric:var(--tw-ordinal,)var(--tw-slashed-zero,)var(--tw-numeric-figure,)var(--tw-numeric-spacing,)var(--tw-numeric-fraction,)}.antialiased{-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}.opacity-0{opacity:0}.opacity-50{opacity:.5}.opacity-100{opacity:1}.opacity-\\[0\\.99\\]{opacity:.99}.brightness-125{--tw-brightness:brightness(125%);filter:var(--tw-blur,)var(--tw-brightness,)var(--tw-contrast,)var(--tw-grayscale,)var(--tw-hue-rotate,)var(--tw-invert,)var(--tw-saturate,)var(--tw-sepia,)var(--tw-drop-shadow,)}.filter{filter:var(--tw-blur,)var(--tw-brightness,)var(--tw-contrast,)var(--tw-grayscale,)var(--tw-hue-rotate,)var(--tw-invert,)var(--tw-saturate,)var(--tw-sepia,)var(--tw-drop-shadow,)}.filter-\\[drop-shadow\\(0px_0px_4px_\\#51515180\\)\\]{filter:drop-shadow(0 0 4px #51515180)}.transition{transition-property:color,background-color,border-color,outline-color,text-decoration-color,fill,stroke,--tw-gradient-from,--tw-gradient-via,--tw-gradient-to,opacity,box-shadow,transform,translate,scale,rotate,filter,-webkit-backdrop-filter,backdrop-filter,display,content-visibility,overlay,pointer-events;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}.transition-\\[grid-template-rows\\]{transition-property:grid-template-rows;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}.transition-\\[width\\,height\\]{transition-property:width,height;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}.transition-all{transition-property:all;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}.transition-opacity{transition-property:opacity;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}.transition-none{transition-property:none}.duration-30{--tw-duration:30ms;transition-duration:30ms}.duration-100{--tw-duration:.1s;transition-duration:.1s}.duration-150{--tw-duration:.15s;transition-duration:.15s}.duration-300{--tw-duration:.3s;transition-duration:.3s}.ease-out{--tw-ease:var(--ease-out);transition-timing-function:var(--ease-out)}.will-change-\\[transform\\,width\\,height\\]{will-change:transform,width,height}.contain-layout{--tw-contain-layout:layout;contain:var(--tw-contain-size,)var(--tw-contain-layout,)var(--tw-contain-paint,)var(--tw-contain-style,)}.outline-none{--tw-outline-style:none;outline-style:none}.\\[font-synthesis\\:none\\]{font-synthesis:none}@media (hover:hover){.hover\\:scale-105:hover{--tw-scale-x:105%;--tw-scale-y:105%;--tw-scale-z:105%;scale:var(--tw-scale-x)var(--tw-scale-y)}.hover\\:text-black:hover{color:var(--color-black)}.hover\\:opacity-100:hover{opacity:1}}}@keyframes spin{0%{transform:rotate(0)}to{transform:rotate(360deg)}}@keyframes shimmer{0%{background-position:200% 0}to{background-position:-200% 0}}@keyframes flash{0%{opacity:1;background-color:#d239c040;border-color:#d239c0}50%{opacity:1;background-color:#d239c073;border-color:#e650d2}to{opacity:1;background-color:#d239c014;border-color:#d239c080}}.react-grab-flash{animation:.4s ease-out forwards flash}.react-grab-shimmer{position:relative;overflow:hidden}.react-grab-shimmer:after{content:"";border-radius:inherit;pointer-events:none;background:linear-gradient(90deg,#0000 0%,#fff6 50%,#0000 100%) 0 0/200% 100%;animation:1.5s ease-in-out infinite shimmer;position:absolute;inset:0}@property --tw-translate-x{syntax:"*";inherits:false;initial-value:0}@property --tw-translate-y{syntax:"*";inherits:false;initial-value:0}@property --tw-translate-z{syntax:"*";inherits:false;initial-value:0}@property --tw-scale-x{syntax:"*";inherits:false;initial-value:1}@property --tw-scale-y{syntax:"*";inherits:false;initial-value:1}@property --tw-scale-z{syntax:"*";inherits:false;initial-value:1}@property --tw-rotate-x{syntax:"*";inherits:false}@property --tw-rotate-y{syntax:"*";inherits:false}@property --tw-rotate-z{syntax:"*";inherits:false}@property --tw-skew-x{syntax:"*";inherits:false}@property --tw-skew-y{syntax:"*";inherits:false}@property --tw-border-style{syntax:"*";inherits:false;initial-value:solid}@property --tw-leading{syntax:"*";inherits:false}@property --tw-font-weight{syntax:"*";inherits:false}@property --tw-tracking{syntax:"*";inherits:false}@property --tw-ordinal{syntax:"*";inherits:false}@property --tw-slashed-zero{syntax:"*";inherits:false}@property --tw-numeric-figure{syntax:"*";inherits:false}@property --tw-numeric-spacing{syntax:"*";inherits:false}@property --tw-numeric-fraction{syntax:"*";inherits:false}@property --tw-blur{syntax:"*";inherits:false}@property --tw-brightness{syntax:"*";inherits:false}@property --tw-contrast{syntax:"*";inherits:false}@property --tw-grayscale{syntax:"*";inherits:false}@property --tw-hue-rotate{syntax:"*";inherits:false}@property --tw-invert{syntax:"*";inherits:false}@property --tw-opacity{syntax:"*";inherits:false}@property --tw-saturate{syntax:"*";inherits:false}@property --tw-sepia{syntax:"*";inherits:false}@property --tw-drop-shadow{syntax:"*";inherits:false}@property --tw-drop-shadow-color{syntax:"*";inherits:false}@property --tw-drop-shadow-alpha{syntax:"<percentage>";inherits:false;initial-value:100%}@property --tw-drop-shadow-size{syntax:"*";inherits:false}@property --tw-duration{syntax:"*";inherits:false}@property --tw-ease{syntax:"*";inherits:false}@property --tw-contain-size{syntax:"*";inherits:false}@property --tw-contain-layout{syntax:"*";inherits:false}@property --tw-contain-paint{syntax:"*";inherits:false}@property --tw-contain-style{syntax:"*";inherits:false}@keyframes pulse{50%{opacity:.5}}`;
891
+ @layer properties{@supports (((-webkit-hyphens:none)) and (not (margin-trim:inline))) or ((-moz-orient:inline) and (not (color:rgb(from red r g b)))){*,:before,:after,::backdrop{--tw-translate-x:0;--tw-translate-y:0;--tw-translate-z:0;--tw-scale-x:1;--tw-scale-y:1;--tw-scale-z:1;--tw-rotate-x:initial;--tw-rotate-y:initial;--tw-rotate-z:initial;--tw-skew-x:initial;--tw-skew-y:initial;--tw-border-style:solid;--tw-leading:initial;--tw-font-weight:initial;--tw-tracking:initial;--tw-ordinal:initial;--tw-slashed-zero:initial;--tw-numeric-figure:initial;--tw-numeric-spacing:initial;--tw-numeric-fraction:initial;--tw-blur:initial;--tw-brightness:initial;--tw-contrast:initial;--tw-grayscale:initial;--tw-hue-rotate:initial;--tw-invert:initial;--tw-opacity:initial;--tw-saturate:initial;--tw-sepia:initial;--tw-drop-shadow:initial;--tw-drop-shadow-color:initial;--tw-drop-shadow-alpha:100%;--tw-drop-shadow-size:initial;--tw-duration:initial;--tw-ease:initial;--tw-contain-size:initial;--tw-contain-layout:initial;--tw-contain-paint:initial;--tw-contain-style:initial}}}@layer theme{:root,:host{--font-sans:ui-sans-serif,system-ui,sans-serif,"Apple Color Emoji","Segoe UI Emoji","Segoe UI Symbol","Noto Color Emoji";--font-mono:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,"Liberation Mono","Courier New",monospace;--color-black:#000;--color-white:#fff;--spacing:.25rem;--font-weight-medium:500;--radius-xs:.125rem;--ease-out:cubic-bezier(0,0,.2,1);--animate-pulse:pulse 2s cubic-bezier(.4,0,.6,1)infinite;--default-transition-duration:.15s;--default-transition-timing-function:cubic-bezier(.4,0,.2,1);--default-font-family:var(--font-sans);--default-mono-font-family:var(--font-mono);--color-grab-pink:#b21c8e;--color-grab-purple:#d239c0;--color-label-tag-border:#730079;--color-label-muted:#767676}}@layer base{*,:after,:before,::backdrop{box-sizing:border-box;border:0 solid;margin:0;padding:0}::file-selector-button{box-sizing:border-box;border:0 solid;margin:0;padding:0}html,:host{-webkit-text-size-adjust:100%;tab-size:4;line-height:1.5;font-family:var(--default-font-family,ui-sans-serif,system-ui,sans-serif,"Apple Color Emoji","Segoe UI Emoji","Segoe UI Symbol","Noto Color Emoji");font-feature-settings:var(--default-font-feature-settings,normal);font-variation-settings:var(--default-font-variation-settings,normal);-webkit-tap-highlight-color:transparent}hr{height:0;color:inherit;border-top-width:1px}abbr:where([title]){-webkit-text-decoration:underline dotted;text-decoration:underline dotted}h1,h2,h3,h4,h5,h6{font-size:inherit;font-weight:inherit}a{color:inherit;-webkit-text-decoration:inherit;-webkit-text-decoration:inherit;-webkit-text-decoration:inherit;text-decoration:inherit}b,strong{font-weight:bolder}code,kbd,samp,pre{font-family:var(--default-mono-font-family,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,"Liberation Mono","Courier New",monospace);font-feature-settings:var(--default-mono-font-feature-settings,normal);font-variation-settings:var(--default-mono-font-variation-settings,normal);font-size:1em}small{font-size:80%}sub,sup{vertical-align:baseline;font-size:75%;line-height:0;position:relative}sub{bottom:-.25em}sup{top:-.5em}table{text-indent:0;border-color:inherit;border-collapse:collapse}:-moz-focusring{outline:auto}progress{vertical-align:baseline}summary{display:list-item}ol,ul,menu{list-style:none}img,svg,video,canvas,audio,iframe,embed,object{vertical-align:middle;display:block}img,video{max-width:100%;height:auto}button,input,select,optgroup,textarea{font:inherit;font-feature-settings:inherit;font-variation-settings:inherit;letter-spacing:inherit;color:inherit;opacity:1;background-color:#0000;border-radius:0}::file-selector-button{font:inherit;font-feature-settings:inherit;font-variation-settings:inherit;letter-spacing:inherit;color:inherit;opacity:1;background-color:#0000;border-radius:0}:where(select:is([multiple],[size])) optgroup{font-weight:bolder}:where(select:is([multiple],[size])) optgroup option{padding-inline-start:20px}::file-selector-button{margin-inline-end:4px}::placeholder{opacity:1}@supports (not ((-webkit-appearance:-apple-pay-button))) or (contain-intrinsic-size:1px){::placeholder{color:currentColor}@supports (color:color-mix(in lab, red, red)){::placeholder{color:color-mix(in oklab,currentcolor 50%,transparent)}}}textarea{resize:vertical}::-webkit-search-decoration{-webkit-appearance:none}::-webkit-date-and-time-value{min-height:1lh;text-align:inherit}::-webkit-datetime-edit{display:inline-flex}::-webkit-datetime-edit-fields-wrapper{padding:0}::-webkit-datetime-edit{padding-block:0}::-webkit-datetime-edit-year-field{padding-block:0}::-webkit-datetime-edit-month-field{padding-block:0}::-webkit-datetime-edit-day-field{padding-block:0}::-webkit-datetime-edit-hour-field{padding-block:0}::-webkit-datetime-edit-minute-field{padding-block:0}::-webkit-datetime-edit-second-field{padding-block:0}::-webkit-datetime-edit-millisecond-field{padding-block:0}::-webkit-datetime-edit-meridiem-field{padding-block:0}::-webkit-calendar-picker-indicator{line-height:1}:-moz-ui-invalid{box-shadow:none}button,input:where([type=button],[type=reset],[type=submit]){appearance:button}::file-selector-button{appearance:button}::-webkit-inner-spin-button{height:auto}::-webkit-outer-spin-button{height:auto}[hidden]:where(:not([hidden=until-found])){display:none!important}}@layer components;@layer utilities{.pointer-events-auto{pointer-events:auto}.pointer-events-none{pointer-events:none}.visible{visibility:visible}.absolute{position:absolute}.fixed{position:fixed}.top-0{top:calc(var(--spacing)*0)}.left-0{left:calc(var(--spacing)*0)}.z-2147483645{z-index:2147483645}.z-2147483646{z-index:2147483646}.z-2147483647{z-index:2147483647}.z-\\[2147483645\\]{z-index:2147483645}.container{width:100%}@media (min-width:40rem){.container{max-width:40rem}}@media (min-width:48rem){.container{max-width:48rem}}@media (min-width:64rem){.container{max-width:64rem}}@media (min-width:80rem){.container{max-width:80rem}}@media (min-width:96rem){.container{max-width:96rem}}.m-0{margin:calc(var(--spacing)*0)}.-ml-\\[2px\\]{margin-left:-2px}.ml-1{margin-left:calc(var(--spacing)*1)}.box-border{box-sizing:border-box}.flex{display:flex}.grid{display:grid}.hidden{display:none}.size-fit{width:fit-content;height:fit-content}.h-0{height:calc(var(--spacing)*0)}.h-4{height:calc(var(--spacing)*4)}.h-5{height:calc(var(--spacing)*5)}.h-5\\.5{height:calc(var(--spacing)*5.5)}.h-\\[7px\\]{height:7px}.h-\\[9px\\]{height:9px}.h-\\[17px\\]{height:17px}.h-\\[18px\\]{height:18px}.h-fit{height:fit-content}.min-h-0{min-height:calc(var(--spacing)*0)}.min-h-4{min-height:calc(var(--spacing)*4)}.w-0{width:calc(var(--spacing)*0)}.w-0\\.5{width:calc(var(--spacing)*.5)}.w-1{width:calc(var(--spacing)*1)}.w-2\\.5{width:calc(var(--spacing)*2.5)}.w-\\[7px\\]{width:7px}.w-\\[17px\\]{width:17px}.w-auto{width:auto}.w-fit{width:fit-content}.w-full{width:100%}.max-w-\\[280px\\]{max-width:280px}.flex-1{flex:1}.shrink{flex-shrink:1}.shrink-0{flex-shrink:0}.-translate-x-1\\/2{--tw-translate-x:calc(calc(1/2*100%)*-1);translate:var(--tw-translate-x)var(--tw-translate-y)}.-translate-y-1\\/2{--tw-translate-y:calc(calc(1/2*100%)*-1);translate:var(--tw-translate-x)var(--tw-translate-y)}.scale-75{--tw-scale-x:75%;--tw-scale-y:75%;--tw-scale-z:75%;scale:var(--tw-scale-x)var(--tw-scale-y)}.scale-100{--tw-scale-x:100%;--tw-scale-y:100%;--tw-scale-z:100%;scale:var(--tw-scale-x)var(--tw-scale-y)}.transform{transform:var(--tw-rotate-x,)var(--tw-rotate-y,)var(--tw-rotate-z,)var(--tw-skew-x,)var(--tw-skew-y,)}.animate-pulse{animation:var(--animate-pulse)}.cursor-crosshair{cursor:crosshair}.cursor-pointer{cursor:pointer}.resize{resize:both}.resize-none{resize:none}.flex-col{flex-direction:column}.items-center{align-items:center}.items-end{align-items:flex-end}.items-start{align-items:flex-start}.justify-between{justify-content:space-between}.justify-center{justify-content:center}.justify-end{justify-content:flex-end}.gap-0\\.5{gap:calc(var(--spacing)*.5)}.gap-1{gap:calc(var(--spacing)*1)}.gap-\\[3px\\]{gap:3px}.gap-\\[5px\\]{gap:5px}.gap-px{gap:1px}.self-stretch{align-self:stretch}.overflow-hidden{overflow:hidden}.overflow-y-auto{overflow-y:auto}.rounded-\\[1\\.5px\\]{border-radius:1.5px}.rounded-\\[1px\\]{border-radius:1px}.rounded-full{border-radius:3.40282e38px}.rounded-xs{border-radius:var(--radius-xs)}.rounded-t-none{border-top-left-radius:0;border-top-right-radius:0}.rounded-b-xs{border-bottom-right-radius:var(--radius-xs);border-bottom-left-radius:var(--radius-xs)}.border{border-style:var(--tw-border-style);border-width:1px}.\\[border-width\\:0\\.5px\\]{border-width:.5px}.\\[border-top-width\\:0\\.5px\\]{border-top-width:.5px}.border-none{--tw-border-style:none;border-style:none}.border-solid{--tw-border-style:solid;border-style:solid}.border-\\[\\#B3B3B3\\]{border-color:#b3b3b3}.border-grab-purple{border-color:var(--color-grab-purple)}.border-grab-purple\\/40{border-color:#d239c066}@supports (color:color-mix(in lab, red, red)){.border-grab-purple\\/40{border-color:color-mix(in oklab,var(--color-grab-purple)40%,transparent)}}.border-grab-purple\\/50{border-color:#d239c080}@supports (color:color-mix(in lab, red, red)){.border-grab-purple\\/50{border-color:color-mix(in oklab,var(--color-grab-purple)50%,transparent)}}.border-label-tag-border{border-color:var(--color-label-tag-border)}.border-white{border-color:var(--color-white)}.border-t-\\[\\#D9D9D9\\]{border-top-color:#d9d9d9}.bg-\\[\\#F7F7F7\\]{background-color:#f7f7f7}.bg-black{background-color:var(--color-black)}.bg-grab-pink{background-color:var(--color-grab-pink)}.bg-grab-purple{background-color:var(--color-grab-purple)}.bg-grab-purple\\/5{background-color:#d239c00d}@supports (color:color-mix(in lab, red, red)){.bg-grab-purple\\/5{background-color:color-mix(in oklab,var(--color-grab-purple)5%,transparent)}}.bg-grab-purple\\/8{background-color:#d239c014}@supports (color:color-mix(in lab, red, red)){.bg-grab-purple\\/8{background-color:color-mix(in oklab,var(--color-grab-purple)8%,transparent)}}.bg-transparent{background-color:#0000}.bg-white{background-color:var(--color-white)}.bg-cover{background-size:cover}.bg-center{background-position:50%}.p-0{padding:calc(var(--spacing)*0)}.p-1{padding:calc(var(--spacing)*1)}.px-0{padding-inline:calc(var(--spacing)*0)}.px-1\\.5{padding-inline:calc(var(--spacing)*1.5)}.px-2{padding-inline:calc(var(--spacing)*2)}.px-\\[2px\\]{padding-inline:2px}.px-\\[3px\\]{padding-inline:3px}.py-0{padding-block:calc(var(--spacing)*0)}.py-1{padding-block:calc(var(--spacing)*1)}.py-\\[2px\\]{padding-block:2px}.py-\\[3px\\]{padding-block:3px}.py-\\[5px\\]{padding-block:5px}.py-px{padding-block:1px}.pt-1{padding-top:calc(var(--spacing)*1)}.pr-1{padding-right:calc(var(--spacing)*1)}.pr-1\\.5{padding-right:calc(var(--spacing)*1.5)}.pl-1\\.5{padding-left:calc(var(--spacing)*1.5)}.align-middle{vertical-align:middle}.font-\\[ui-monospace\\,\\'SFMono-Regular\\'\\,\\'SF_Mono\\'\\,\\'Menlo\\'\\,\\'Consolas\\'\\,\\'Liberation_Mono\\'\\,monospace\\]{font-family:ui-monospace,SFMono-Regular,SF Mono,Menlo,Consolas,Liberation Mono,monospace}.font-mono{font-family:var(--font-mono)}.font-sans{font-family:var(--font-sans)}.text-\\[11\\.5px\\]{font-size:11.5px}.text-\\[12px\\]{font-size:12px}.leading-3\\.5{--tw-leading:calc(var(--spacing)*3.5);line-height:calc(var(--spacing)*3.5)}.leading-4{--tw-leading:calc(var(--spacing)*4);line-height:calc(var(--spacing)*4)}.font-medium{--tw-font-weight:var(--font-weight-medium);font-weight:var(--font-weight-medium)}.tracking-\\[-0\\.04em\\]{--tw-tracking:-.04em;letter-spacing:-.04em}.tracking-\\[-0\\.08em\\]{--tw-tracking:-.08em;letter-spacing:-.08em}.wrap-break-word{overflow-wrap:break-word}.whitespace-normal{white-space:normal}.text-\\[\\#0C0C0C\\]{color:#0c0c0c}.text-\\[\\#47004A\\]{color:#47004a}.text-black{color:var(--color-black)}.text-label-muted{color:var(--color-label-muted)}.text-label-tag-border{color:var(--color-label-tag-border)}.text-white{color:var(--color-white)}.tabular-nums{--tw-numeric-spacing:tabular-nums;font-variant-numeric:var(--tw-ordinal,)var(--tw-slashed-zero,)var(--tw-numeric-figure,)var(--tw-numeric-spacing,)var(--tw-numeric-fraction,)}.antialiased{-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}.opacity-0{opacity:0}.opacity-50{opacity:.5}.opacity-100{opacity:1}.opacity-\\[0\\.99\\]{opacity:.99}.brightness-125{--tw-brightness:brightness(125%);filter:var(--tw-blur,)var(--tw-brightness,)var(--tw-contrast,)var(--tw-grayscale,)var(--tw-hue-rotate,)var(--tw-invert,)var(--tw-saturate,)var(--tw-sepia,)var(--tw-drop-shadow,)}.filter{filter:var(--tw-blur,)var(--tw-brightness,)var(--tw-contrast,)var(--tw-grayscale,)var(--tw-hue-rotate,)var(--tw-invert,)var(--tw-saturate,)var(--tw-sepia,)var(--tw-drop-shadow,)}.filter-\\[drop-shadow\\(0px_0px_4px_\\#51515180\\)\\]{filter:drop-shadow(0 0 4px #51515180)}.transition{transition-property:color,background-color,border-color,outline-color,text-decoration-color,fill,stroke,--tw-gradient-from,--tw-gradient-via,--tw-gradient-to,opacity,box-shadow,transform,translate,scale,rotate,filter,-webkit-backdrop-filter,backdrop-filter,display,content-visibility,overlay,pointer-events;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}.transition-\\[grid-template-rows\\]{transition-property:grid-template-rows;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}.transition-\\[width\\,height\\]{transition-property:width,height;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}.transition-all{transition-property:all;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}.transition-opacity{transition-property:opacity;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}.transition-none{transition-property:none}.duration-30{--tw-duration:30ms;transition-duration:30ms}.duration-100{--tw-duration:.1s;transition-duration:.1s}.duration-150{--tw-duration:.15s;transition-duration:.15s}.duration-300{--tw-duration:.3s;transition-duration:.3s}.ease-out{--tw-ease:var(--ease-out);transition-timing-function:var(--ease-out)}.will-change-\\[transform\\,width\\,height\\]{will-change:transform,width,height}.contain-layout{--tw-contain-layout:layout;contain:var(--tw-contain-size,)var(--tw-contain-layout,)var(--tw-contain-paint,)var(--tw-contain-style,)}.outline-none{--tw-outline-style:none;outline-style:none}.select-none{-webkit-user-select:none;user-select:none}.\\[font-synthesis\\:none\\]{font-synthesis:none}@media (hover:hover){.hover\\:scale-105:hover{--tw-scale-x:105%;--tw-scale-y:105%;--tw-scale-z:105%;scale:var(--tw-scale-x)var(--tw-scale-y)}.hover\\:opacity-100:hover{opacity:1}}}@keyframes spin{0%{transform:rotate(0)}to{transform:rotate(360deg)}}@keyframes shimmer{0%{background-position:200% 0}to{background-position:-200% 0}}@keyframes flash{0%{opacity:1;background-color:#d239c040;border-color:#d239c0}50%{opacity:1;background-color:#d239c073;border-color:#e650d2}to{opacity:1;background-color:#d239c014;border-color:#d239c080}}.react-grab-flash{animation:.4s ease-out forwards flash}.react-grab-shimmer{position:relative;overflow:hidden}.react-grab-shimmer:after{content:"";border-radius:inherit;pointer-events:none;background:linear-gradient(90deg,#0000 0%,#fff6 50%,#0000 100%) 0 0/200% 100%;animation:1.5s ease-in-out infinite shimmer;position:absolute;inset:0}@property --tw-translate-x{syntax:"*";inherits:false;initial-value:0}@property --tw-translate-y{syntax:"*";inherits:false;initial-value:0}@property --tw-translate-z{syntax:"*";inherits:false;initial-value:0}@property --tw-scale-x{syntax:"*";inherits:false;initial-value:1}@property --tw-scale-y{syntax:"*";inherits:false;initial-value:1}@property --tw-scale-z{syntax:"*";inherits:false;initial-value:1}@property --tw-rotate-x{syntax:"*";inherits:false}@property --tw-rotate-y{syntax:"*";inherits:false}@property --tw-rotate-z{syntax:"*";inherits:false}@property --tw-skew-x{syntax:"*";inherits:false}@property --tw-skew-y{syntax:"*";inherits:false}@property --tw-border-style{syntax:"*";inherits:false;initial-value:solid}@property --tw-leading{syntax:"*";inherits:false}@property --tw-font-weight{syntax:"*";inherits:false}@property --tw-tracking{syntax:"*";inherits:false}@property --tw-ordinal{syntax:"*";inherits:false}@property --tw-slashed-zero{syntax:"*";inherits:false}@property --tw-numeric-figure{syntax:"*";inherits:false}@property --tw-numeric-spacing{syntax:"*";inherits:false}@property --tw-numeric-fraction{syntax:"*";inherits:false}@property --tw-blur{syntax:"*";inherits:false}@property --tw-brightness{syntax:"*";inherits:false}@property --tw-contrast{syntax:"*";inherits:false}@property --tw-grayscale{syntax:"*";inherits:false}@property --tw-hue-rotate{syntax:"*";inherits:false}@property --tw-invert{syntax:"*";inherits:false}@property --tw-opacity{syntax:"*";inherits:false}@property --tw-saturate{syntax:"*";inherits:false}@property --tw-sepia{syntax:"*";inherits:false}@property --tw-drop-shadow{syntax:"*";inherits:false}@property --tw-drop-shadow-color{syntax:"*";inherits:false}@property --tw-drop-shadow-alpha{syntax:"<percentage>";inherits:false;initial-value:100%}@property --tw-drop-shadow-size{syntax:"*";inherits:false}@property --tw-duration{syntax:"*";inherits:false}@property --tw-ease{syntax:"*";inherits:false}@property --tw-contain-size{syntax:"*";inherits:false}@property --tw-contain-layout{syntax:"*";inherits:false}@property --tw-contain-paint{syntax:"*";inherits:false}@property --tw-contain-style{syntax:"*";inherits:false}@keyframes pulse{50%{opacity:.5}}`;
892
892
 
893
893
  // src/utils/is-keyboard-event-triggered-by-input.ts
894
894
  var FORM_TAGS_AND_ROLES = [
@@ -1017,7 +1017,7 @@ var buildOpenFileUrl = (filePath, lineNumber) => {
1017
1017
  };
1018
1018
 
1019
1019
  // src/constants.ts
1020
- var VERSION = "0.0.69";
1020
+ var VERSION = "0.0.71";
1021
1021
  var VIEWPORT_MARGIN_PX = 8;
1022
1022
  var OFFSCREEN_POSITION = -1e3;
1023
1023
  var SELECTION_LERP_FACTOR = 0.95;
@@ -1027,6 +1027,7 @@ var SELECTION_CURSOR_SETTLE_DELAY_MS = 500;
1027
1027
  var BLUR_DEACTIVATION_THRESHOLD_MS = 500;
1028
1028
  var DRAG_THRESHOLD_PX = 2;
1029
1029
  var ELEMENT_DETECTION_THROTTLE_MS = 32;
1030
+ var BOUNDS_RECALC_INTERVAL_MS = 100;
1030
1031
  var AUTO_SCROLL_EDGE_THRESHOLD_PX = 25;
1031
1032
  var AUTO_SCROLL_SPEED_PX = 10;
1032
1033
  var Z_INDEX_LABEL = 2147483647;
@@ -3865,16 +3866,17 @@ var _tmpl$42 = /* @__PURE__ */ template(`<div class="absolute w-0 h-0"style="bor
3865
3866
  var _tmpl$52 = /* @__PURE__ */ template(`<div role=button><div class="text-black text-[12px] leading-4 shrink-0 tracking-[-0.04em] font-sans font-medium w-fit h-fit">`);
3866
3867
  var _tmpl$6 = /* @__PURE__ */ template(`<div class="[font-synthesis:none] contain-layout shrink-0 flex flex-col items-start px-2 py-[5px] w-auto h-fit self-stretch [border-top-width:0.5px] border-t-solid border-t-[#D9D9D9] antialiased rounded-t-none rounded-b-xs"style="background-image:linear-gradient(in oklab 180deg, oklab(100% 0 0) 0%, oklab(96.1% 0 0) 5.92%)">`);
3867
3868
  var _tmpl$7 = /* @__PURE__ */ template(`<div class="[font-synthesis:none] contain-layout shrink-0 flex items-center gap-1 rounded-xs bg-white antialiased w-fit h-fit py-1 px-1.5"><div class="contain-layout shrink-0 flex items-center px-0 py-px w-fit h-[18px] rounded-[1.5px] gap-[3px]"><div class="text-black text-[12px] leading-4 shrink-0 tracking-[-0.04em] font-sans font-medium w-fit h-fit">`);
3868
- var _tmpl$8 = /* @__PURE__ */ template(`<button class="contain-layout shrink-0 flex flex-col items-start rounded-xs bg-white [border-width:0.5px] border-solid border-[#B3B3B3] p-1 size-fit cursor-pointer ml-1 transition-none hover:scale-105"><div class="shrink-0 w-[7px] h-[7px] rounded-[1px] bg-black">`);
3869
- var _tmpl$9 = /* @__PURE__ */ template(`<div class="shrink-0 flex justify-between items-end w-full min-h-4"><textarea class="text-black text-[12px] leading-4 tracking-[-0.04em] font-medium bg-transparent border-none outline-none resize-none flex-1 p-0 m-0 opacity-50 break-all"placeholder="type to edit"rows=1 disabled style=field-sizing:content;min-height:16px>`);
3869
+ var _tmpl$8 = /* @__PURE__ */ template(`<button data-react-grab-ignore-events class="contain-layout shrink-0 flex flex-col items-start rounded-xs bg-white [border-width:0.5px] border-solid border-[#B3B3B3] p-1 size-fit cursor-pointer ml-1 transition-none hover:scale-105"><div data-react-grab-ignore-events class="shrink-0 w-[7px] h-[7px] rounded-[1px] bg-black pointer-events-none">`);
3870
+ var _tmpl$9 = /* @__PURE__ */ template(`<div class="shrink-0 flex justify-between items-end w-full min-h-4"><textarea class="text-black text-[12px] leading-4 tracking-[-0.04em] font-medium bg-transparent border-none outline-none resize-none flex-1 p-0 m-0 opacity-50 wrap-break-word overflow-y-auto"placeholder="type to edit"rows=1 disabled style=field-sizing:content;min-height:16px;max-height:95px;scrollbar-width:none>`);
3870
3871
  var _tmpl$0 = /* @__PURE__ */ template(`<div class="contain-layout shrink-0 flex flex-col justify-center items-start gap-1 w-fit h-fit max-w-[280px]"><div class="contain-layout shrink-0 flex items-center gap-1 pt-1 px-1.5 w-auto h-fit"><div class="contain-layout flex items-center px-0 py-px w-auto h-fit rounded-[1.5px] gap-[3px]"><div class="text-black text-[12px] leading-4 tracking-[-0.04em] font-sans font-medium w-auto h-fit whitespace-normal react-grab-shimmer">`);
3871
3872
  var _tmpl$1 = /* @__PURE__ */ template(`<div class="contain-layout shrink-0 flex items-center gap-px w-fit h-fit">`);
3872
3873
  var _tmpl$10 = /* @__PURE__ */ template(`<div class="contain-layout shrink-0 flex items-center gap-1 w-fit h-fit"><span class="text-label-muted text-[12px] leading-4 shrink-0 tracking-[-0.04em] font-sans font-medium w-fit h-fit">Press</span><div class="contain-layout shrink-0 flex flex-col items-start px-[3px] py-[3px] rounded-xs bg-white [border-width:0.5px] border-solid border-[#B3B3B3] size-fit"><div class="w-2.5 h-[9px] shrink-0 opacity-[0.99] bg-cover bg-center"style=background-image:url(https://workers.paper.design/file-assets/01K8D51Q7E2ESJTN18XN2MT96X/01KBEJ7N5GQ0ZZ7K456R42AP4V.svg)></div></div><span class="text-label-muted text-[12px] leading-4 shrink-0 tracking-[-0.04em] font-sans font-medium w-fit h-fit">to edit`);
3873
- var _tmpl$11 = /* @__PURE__ */ template(`<div class="contain-layout shrink-0 flex flex-col justify-center items-start gap-1 w-fit h-fit"><div class="contain-layout shrink-0 flex items-center gap-1 pt-1 w-fit h-fit px-1.5"></div><div class="grid w-full transition-[grid-template-rows] duration-30 ease-out"><div class="overflow-hidden min-h-0">`);
3874
+ var _tmpl$11 = /* @__PURE__ */ template(`<div class="contain-layout shrink-0 flex flex-col justify-center items-start gap-1 w-fit h-fit"><div></div><div class="grid transition-[grid-template-rows] duration-30 ease-out"><div>`);
3874
3875
  var _tmpl$12 = /* @__PURE__ */ template(`<button>`);
3875
- var _tmpl$13 = /* @__PURE__ */ template(`<div class="shrink-0 flex justify-between items-end w-full min-h-4"><textarea class="text-black text-[12px] leading-4 tracking-[-0.04em] font-medium bg-transparent border-none outline-none resize-none flex-1 p-0 m-0 break-all"rows=1 style=field-sizing:content;min-height:16px></textarea><div class="flex items-center gap-0.5 ml-1"><button class="contain-layout shrink-0 flex flex-col items-start px-[3px] py-[3px] rounded-xs bg-white [border-width:0.5px] border-solid border-[#B3B3B3] size-fit cursor-pointer transition-none hover:scale-105"><div style=background-image:url(https://workers.paper.design/file-assets/01K8D51Q7E2ESJTN18XN2MT96X/01KBEJ7N5GQ0ZZ7K456R42AP4V.svg)>`);
3876
- var _tmpl$14 = /* @__PURE__ */ template(`<div class="contain-layout shrink-0 flex flex-col justify-center items-start gap-1 w-fit h-fit max-w-[280px]"><div class="contain-layout shrink-0 flex items-center gap-1 pt-1 px-1.5 w-fit h-fit">`);
3877
- var _tmpl$15 = /* @__PURE__ */ template(`<div data-react-grab-ignore-events class="fixed font-sans antialiased transition-opacity duration-300 ease-out filter-[drop-shadow(0px_0px_4px_#51515180)]"style=z-index:2147483647><div class="[font-synthesis:none] contain-layout flex items-center gap-[5px] rounded-xs bg-white antialiased w-fit h-fit p-0">`);
3876
+ var _tmpl$13 = /* @__PURE__ */ template(`<button class="contain-layout shrink-0 flex flex-col items-start px-[3px] py-[3px] rounded-xs bg-white [border-width:0.5px] border-solid border-[#B3B3B3] size-fit cursor-pointer transition-all hover:scale-105"><div class="w-2.5 h-[9px] shrink-0 bg-cover bg-center opacity-[0.99]"style=background-image:url(https://workers.paper.design/file-assets/01K8D51Q7E2ESJTN18XN2MT96X/01KBEJ7N5GQ0ZZ7K456R42AP4V.svg)>`);
3877
+ var _tmpl$14 = /* @__PURE__ */ template(`<div class="shrink-0 flex justify-between items-end w-full min-h-4"><textarea class="text-black text-[12px] leading-4 tracking-[-0.04em] font-medium bg-transparent border-none outline-none resize-none flex-1 p-0 m-0 wrap-break-word overflow-y-auto"rows=1 style=field-sizing:content;min-height:16px;max-height:95px;scrollbar-width:none></textarea><div class="flex items-center gap-0.5 ml-1 w-[17px] h-[17px] justify-end">`);
3878
+ var _tmpl$15 = /* @__PURE__ */ template(`<div class="contain-layout shrink-0 flex flex-col justify-center items-start gap-1 w-fit h-fit max-w-[280px]"><div>`);
3879
+ var _tmpl$16 = /* @__PURE__ */ template(`<div data-react-grab-ignore-events class="fixed font-sans antialiased transition-opacity duration-300 ease-out filter-[drop-shadow(0px_0px_4px_#51515180)] select-none"style=z-index:2147483647><div class="[font-synthesis:none] contain-layout flex items-center gap-[5px] rounded-xs bg-white antialiased w-fit h-fit p-0">`);
3878
3880
  var ARROW_HEIGHT = 8;
3879
3881
  var LABEL_GAP = 4;
3880
3882
  var IDLE_TIMEOUT_MS = 400;
@@ -4101,6 +4103,7 @@ var SelectionLabel = (props) => {
4101
4103
  event.stopImmediatePropagation();
4102
4104
  if (event.code === "Enter" && !event.shiftKey) {
4103
4105
  event.preventDefault();
4106
+ if (!props.inputValue?.trim()) return;
4104
4107
  speechRecognition.stop();
4105
4108
  props.onSubmit?.();
4106
4109
  } else if (event.code === "Escape") {
@@ -4127,6 +4130,7 @@ var SelectionLabel = (props) => {
4127
4130
  event.stopImmediatePropagation();
4128
4131
  };
4129
4132
  const handleSubmit = () => {
4133
+ if (props.isInputExpanded && !props.inputValue?.trim()) return;
4130
4134
  speechRecognition.stop();
4131
4135
  props.onSubmit?.();
4132
4136
  };
@@ -4135,7 +4139,7 @@ var SelectionLabel = (props) => {
4135
4139
  return memo(() => props.visible !== false)() && props.selectionBounds;
4136
4140
  },
4137
4141
  get children() {
4138
- var _el$0 = _tmpl$15(), _el$12 = _el$0.firstChild;
4142
+ var _el$0 = _tmpl$16(), _el$12 = _el$0.firstChild;
4139
4143
  _el$0.$$click = stopPropagation;
4140
4144
  _el$0.$$mousedown = stopPropagation;
4141
4145
  _el$0.$$pointerdown = stopPropagation;
@@ -4177,7 +4181,16 @@ var SelectionLabel = (props) => {
4177
4181
  },
4178
4182
  get children() {
4179
4183
  var _el$19 = _tmpl$8();
4180
- addEventListener(_el$19, "click", props.onAbort);
4184
+ _el$19.$$click = (event) => {
4185
+ event.stopPropagation();
4186
+ props.onAbort?.();
4187
+ };
4188
+ _el$19.$$pointerup = (event) => {
4189
+ event.stopPropagation();
4190
+ props.onAbort?.();
4191
+ };
4192
+ _el$19.$$mousedown = (event) => event.stopPropagation();
4193
+ _el$19.$$pointerdown = (event) => event.stopPropagation();
4181
4194
  return _el$19;
4182
4195
  }
4183
4196
  }), null);
@@ -4256,7 +4269,17 @@ var SelectionLabel = (props) => {
4256
4269
  return _el$25;
4257
4270
  }
4258
4271
  }));
4259
- createRenderEffect((_$p) => setStyleProperty(_el$23, "grid-template-rows", isIdle() ? "1fr" : "0fr"));
4272
+ createRenderEffect((_p$) => {
4273
+ var _v$3 = cn("contain-layout shrink-0 flex items-center gap-1 pt-1 w-fit h-fit pl-1.5", props.componentName ? "pr-1.5" : "pr-1"), _v$4 = isIdle() ? "1fr" : "0fr", _v$5 = cn("overflow-hidden min-h-0", !isIdle() && "w-0");
4274
+ _v$3 !== _p$.e && className(_el$21, _p$.e = _v$3);
4275
+ _v$4 !== _p$.t && setStyleProperty(_el$23, "grid-template-rows", _p$.t = _v$4);
4276
+ _v$5 !== _p$.a && className(_el$24, _p$.a = _v$5);
4277
+ return _p$;
4278
+ }, {
4279
+ e: void 0,
4280
+ t: void 0,
4281
+ a: void 0
4282
+ });
4260
4283
  return _el$20;
4261
4284
  }
4262
4285
  }), null);
@@ -4265,7 +4288,7 @@ var SelectionLabel = (props) => {
4265
4288
  return memo(() => !!isNotProcessing())() && props.isInputExpanded;
4266
4289
  },
4267
4290
  get children() {
4268
- var _el$29 = _tmpl$14(), _el$30 = _el$29.firstChild;
4291
+ var _el$29 = _tmpl$15(), _el$30 = _el$29.firstChild;
4269
4292
  insert(_el$30, createComponent(ClickToCopyPill, {
4270
4293
  onClick: handleSubmit,
4271
4294
  dimmed: true,
@@ -4327,14 +4350,14 @@ var SelectionLabel = (props) => {
4327
4350
  }), null);
4328
4351
  insert(_el$29, createComponent(BottomSection, {
4329
4352
  get children() {
4330
- var _el$32 = _tmpl$13(), _el$33 = _el$32.firstChild, _el$34 = _el$33.nextSibling, _el$36 = _el$34.firstChild, _el$37 = _el$36.firstChild;
4353
+ var _el$32 = _tmpl$14(), _el$33 = _el$32.firstChild, _el$34 = _el$33.nextSibling;
4331
4354
  _el$33.$$keydown = handleKeyDown;
4332
4355
  _el$33.$$input = handleInput;
4333
4356
  var _ref$3 = inputRef;
4334
4357
  typeof _ref$3 === "function" ? use(_ref$3, _el$33) : inputRef = _el$33;
4335
4358
  insert(_el$34, createComponent(Show, {
4336
4359
  get when() {
4337
- return memo(() => !!props.hasAgent)() && speechRecognition.isSupported();
4360
+ return memo(() => !!(props.hasAgent && speechRecognition.isSupported()))() && !props.inputValue;
4338
4361
  },
4339
4362
  get children() {
4340
4363
  var _el$35 = _tmpl$12();
@@ -4346,9 +4369,9 @@ var SelectionLabel = (props) => {
4346
4369
  }
4347
4370
  }));
4348
4371
  createRenderEffect((_p$) => {
4349
- var _v$3 = cn("contain-layout shrink-0 flex items-center justify-center px-[3px] py-[3px] rounded-xs [border-width:0.5px] border-solid size-fit cursor-pointer transition-all hover:scale-105", speechRecognition.isListening() ? "bg-grab-purple border-grab-purple text-white" : "bg-white border-[#B3B3B3] text-black/50 hover:text-black"), _v$4 = speechRecognition.isListening() ? "Stop listening" : "Start voice input";
4350
- _v$3 !== _p$.e && className(_el$35, _p$.e = _v$3);
4351
- _v$4 !== _p$.t && setAttribute(_el$35, "title", _p$.t = _v$4);
4372
+ var _v$6 = cn("contain-layout shrink-0 flex items-center justify-center px-[2px] py-[2px] rounded-xs [border-width:0.5px] border-solid size-fit cursor-pointer transition-all hover:scale-105", speechRecognition.isListening() ? "bg-grab-purple border-grab-purple text-white" : "bg-white border-[#B3B3B3] text-black"), _v$7 = speechRecognition.isListening() ? "Stop listening" : "Start voice input";
4373
+ _v$6 !== _p$.e && className(_el$35, _p$.e = _v$6);
4374
+ _v$7 !== _p$.t && setAttribute(_el$35, "title", _p$.t = _v$7);
4352
4375
  return _p$;
4353
4376
  }, {
4354
4377
  e: void 0,
@@ -4356,31 +4379,33 @@ var SelectionLabel = (props) => {
4356
4379
  });
4357
4380
  return _el$35;
4358
4381
  }
4359
- }), _el$36);
4360
- _el$36.$$click = handleSubmit;
4361
- createRenderEffect((_p$) => {
4362
- var _v$5 = speechRecognition.isListening() ? "listening..." : props.hasAgent ? "type or speak to edit" : "type to edit", _v$6 = cn("w-2.5 h-[9px] shrink-0 bg-cover bg-center transition-opacity duration-100", props.inputValue ? "opacity-[0.99]" : "opacity-50");
4363
- _v$5 !== _p$.e && setAttribute(_el$33, "placeholder", _p$.e = _v$5);
4364
- _v$6 !== _p$.t && className(_el$37, _p$.t = _v$6);
4365
- return _p$;
4366
- }, {
4367
- e: void 0,
4368
- t: void 0
4369
- });
4382
+ }), null);
4383
+ insert(_el$34, createComponent(Show, {
4384
+ get when() {
4385
+ return props.inputValue;
4386
+ },
4387
+ get children() {
4388
+ var _el$36 = _tmpl$13(); _el$36.firstChild;
4389
+ _el$36.$$click = handleSubmit;
4390
+ return _el$36;
4391
+ }
4392
+ }), null);
4393
+ createRenderEffect(() => setAttribute(_el$33, "placeholder", speechRecognition.isListening() ? "listening..." : props.hasAgent ? "type to edit" : "type prompt"));
4370
4394
  createRenderEffect(() => _el$33.value = props.inputValue ?? "");
4371
4395
  return _el$32;
4372
4396
  }
4373
4397
  }), null);
4398
+ createRenderEffect(() => className(_el$30, cn("contain-layout shrink-0 flex items-center gap-1 pt-1 w-fit h-fit pl-1.5", props.componentName ? "pr-1.5" : "pr-1")));
4374
4399
  return _el$29;
4375
4400
  }
4376
4401
  }), null);
4377
4402
  createRenderEffect((_p$) => {
4378
- var _v$7 = `${computedPosition().top}px`, _v$8 = `${computedPosition().left}px`, _v$9 = props.visible ? "auto" : "none", _v$0 = props.status === "fading" ? 0 : 1, _v$1 = props.status === "copied" || props.status === "fading" ? "none" : void 0;
4379
- _v$7 !== _p$.e && setStyleProperty(_el$0, "top", _p$.e = _v$7);
4380
- _v$8 !== _p$.t && setStyleProperty(_el$0, "left", _p$.t = _v$8);
4381
- _v$9 !== _p$.a && setStyleProperty(_el$0, "pointer-events", _p$.a = _v$9);
4382
- _v$0 !== _p$.o && setStyleProperty(_el$0, "opacity", _p$.o = _v$0);
4383
- _v$1 !== _p$.i && setStyleProperty(_el$12, "display", _p$.i = _v$1);
4403
+ var _v$8 = `${computedPosition().top}px`, _v$9 = `${computedPosition().left}px`, _v$0 = props.isInputExpanded ? "auto" : "none", _v$1 = props.status === "fading" ? 0 : 1, _v$10 = props.status === "copied" || props.status === "fading" ? "none" : void 0;
4404
+ _v$8 !== _p$.e && setStyleProperty(_el$0, "top", _p$.e = _v$8);
4405
+ _v$9 !== _p$.t && setStyleProperty(_el$0, "left", _p$.t = _v$9);
4406
+ _v$0 !== _p$.a && setStyleProperty(_el$0, "pointer-events", _p$.a = _v$0);
4407
+ _v$1 !== _p$.o && setStyleProperty(_el$0, "opacity", _p$.o = _v$1);
4408
+ _v$10 !== _p$.i && setStyleProperty(_el$12, "display", _p$.i = _v$10);
4384
4409
  return _p$;
4385
4410
  }, {
4386
4411
  e: void 0,
@@ -4393,10 +4418,10 @@ var SelectionLabel = (props) => {
4393
4418
  }
4394
4419
  });
4395
4420
  };
4396
- delegateEvents(["click", "pointerdown", "mousedown", "input", "keydown"]);
4421
+ delegateEvents(["click", "pointerdown", "mousedown", "pointerup", "input", "keydown"]);
4397
4422
 
4398
4423
  // src/components/selection-cursor.tsx
4399
- var _tmpl$16 = /* @__PURE__ */ template(`<div class="fixed z-2147483647"><button data-react-grab-selection-cursor>`);
4424
+ var _tmpl$17 = /* @__PURE__ */ template(`<div class="fixed z-2147483647"><button data-react-grab-selection-cursor>`);
4400
4425
  var SelectionCursor = (props) => {
4401
4426
  const [isHovered, setIsHovered] = createSignal(false);
4402
4427
  const [debouncedVisible, setDebouncedVisible] = createSignal(false);
@@ -4433,7 +4458,7 @@ var SelectionCursor = (props) => {
4433
4458
  });
4434
4459
  }
4435
4460
  }), (() => {
4436
- var _el$ = _tmpl$16(), _el$2 = _el$.firstChild;
4461
+ var _el$ = _tmpl$17(), _el$2 = _el$.firstChild;
4437
4462
  _el$.addEventListener("mouseleave", () => setIsHovered(false));
4438
4463
  _el$.addEventListener("mouseenter", () => setIsHovered(true));
4439
4464
  _el$2.$$click = handleClick;
@@ -4578,7 +4603,7 @@ var ReactGrabRenderer = (props) => {
4578
4603
  return session.isStreaming ? "copying" : "copied";
4579
4604
  },
4580
4605
  get statusText() {
4581
- return session.lastStatus || "Please wait\u2026";
4606
+ return session.lastStatus || "Thinking\u2026";
4582
4607
  },
4583
4608
  get inputValue() {
4584
4609
  return session.context.prompt;
@@ -5998,7 +6023,7 @@ var isTargetKeyCombination = (event, options) => {
5998
6023
  ].filter(Boolean).length;
5999
6024
  return allRequiredModifiersPressed && pressedModifierCount >= requiredModifierCount;
6000
6025
  }
6001
- const keyMatches = event.key.toLowerCase() === key.toLowerCase() || keyMatchesCode(key, event.code);
6026
+ const keyMatches = event.key?.toLowerCase() === key.toLowerCase() || keyMatchesCode(key, event.code);
6002
6027
  const hasModifier = metaKey || ctrlKey || shiftKey || altKey;
6003
6028
  const modifiersMatch = hasModifier ? (metaKey ? event.metaKey : true) && (ctrlKey ? event.ctrlKey : true) && (shiftKey ? event.shiftKey : true) && (altKey ? event.altKey : true) : event.metaKey || event.ctrlKey;
6004
6029
  return keyMatches && modifiersMatch;
@@ -6027,9 +6052,6 @@ var DEFAULT_THEME = {
6027
6052
  elementLabel: {
6028
6053
  enabled: true
6029
6054
  },
6030
- successLabels: {
6031
- enabled: true
6032
- },
6033
6055
  crosshair: {
6034
6056
  enabled: true
6035
6057
  }
@@ -6049,9 +6071,6 @@ var mergeThemeWithBase = (baseTheme, partialTheme) => ({
6049
6071
  elementLabel: {
6050
6072
  enabled: partialTheme.elementLabel?.enabled ?? baseTheme.elementLabel.enabled
6051
6073
  },
6052
- successLabels: {
6053
- enabled: partialTheme.successLabels?.enabled ?? baseTheme.successLabels.enabled
6054
- },
6055
6074
  crosshair: {
6056
6075
  enabled: partialTheme.crosshair?.enabled ?? baseTheme.crosshair.enabled
6057
6076
  }
@@ -6338,7 +6357,7 @@ var createAgentManager = (initialAgentOptions) => {
6338
6357
  tagName,
6339
6358
  componentName
6340
6359
  );
6341
- session.lastStatus = "Please wait\u2026";
6360
+ session.lastStatus = "Thinking\u2026";
6342
6361
  sessionElements.set(session.id, element);
6343
6362
  setSessions((prev) => new Map(prev).set(session.id, session));
6344
6363
  saveSessionById(session, storage);
@@ -6419,7 +6438,7 @@ var createAgentManager = (initialAgentOptions) => {
6419
6438
  };
6420
6439
 
6421
6440
  // src/core.tsx
6422
- var _tmpl$17 = /* @__PURE__ */ template(`<span class="tabular-nums align-middle">`);
6441
+ var _tmpl$18 = /* @__PURE__ */ template(`<span class="tabular-nums align-middle">`);
6423
6442
  var _tmpl$23 = /* @__PURE__ */ template(`<span class="font-mono tabular-nums align-middle">&lt;<!>>`);
6424
6443
  var _tmpl$33 = /* @__PURE__ */ template(`<span class="tabular-nums ml-1 align-middle"> in `);
6425
6444
  var onIdle = (callback) => {
@@ -6513,7 +6532,7 @@ var init = (rawOptions) => {
6513
6532
  hasInited = true;
6514
6533
  const logIntro = () => {
6515
6534
  try {
6516
- const version = "0.0.69";
6535
+ const version = "0.0.71";
6517
6536
  const logoDataUri = `data:image/svg+xml;base64,${btoa(LOGO_SVG)}`;
6518
6537
  console.log(`%cReact Grab${version ? ` v${version}` : ""}%c
6519
6538
  https://react-grab.com`, `background: #330039; color: #ffffff; border: 1px solid #d75fcb; padding: 4px 4px 4px 24px; border-radius: 4px; background-image: url("${logoDataUri}"); background-size: 16px 16px; background-repeat: no-repeat; background-position: 4px center; display: inline-block; margin-bottom: 4px;`, "");
@@ -6549,10 +6568,10 @@ https://react-grab.com`, `background: #330039; color: #ffffff; border: 1px solid
6549
6568
  const [lastGrabbedElement, setLastGrabbedElement] = createSignal(null);
6550
6569
  const [progressStartTime, setProgressStartTime] = createSignal(null);
6551
6570
  const [grabbedBoxes, setGrabbedBoxes] = createSignal([]);
6552
- const [successLabels, setSuccessLabels] = createSignal([]);
6553
6571
  const [isActivated, setIsActivated] = createSignal(false);
6554
6572
  const [isToggleMode, setIsToggleMode] = createSignal(false);
6555
6573
  const [didJustDrag, setDidJustDrag] = createSignal(false);
6574
+ const [didJustCopy, setDidJustCopy] = createSignal(false);
6556
6575
  const [copyStartX, setCopyStartX] = createSignal(OFFSCREEN_POSITION);
6557
6576
  const [copyStartY, setCopyStartY] = createSignal(OFFSCREEN_POSITION);
6558
6577
  const [copyOffsetFromCenterX, setCopyOffsetFromCenterX] = createSignal(0);
@@ -6566,6 +6585,7 @@ https://react-grab.com`, `background: #330039; color: #ffffff; border: 1px solid
6566
6585
  const [isInputExpanded, setIsInputExpanded] = createSignal(false);
6567
6586
  const [frozenElement, setFrozenElement] = createSignal(null);
6568
6587
  const [hasAgentProvider, setHasAgentProvider] = createSignal(Boolean(options.agent?.provider));
6588
+ const elementInputCache = /* @__PURE__ */ new WeakMap();
6569
6589
  const [nativeSelectionCursorX, setNativeSelectionCursorX] = createSignal(OFFSCREEN_POSITION);
6570
6590
  const [nativeSelectionCursorY, setNativeSelectionCursorY] = createSignal(OFFSCREEN_POSITION);
6571
6591
  const [hasNativeSelection, setHasNativeSelection] = createSignal(false);
@@ -6652,24 +6672,6 @@ https://react-grab.com`, `background: #330039; color: #ffffff; border: 1px solid
6652
6672
  setGrabbedBoxes((previousBoxes) => previousBoxes.filter((box) => box.id !== boxId));
6653
6673
  }, SUCCESS_LABEL_DURATION_MS);
6654
6674
  };
6655
- const showTemporarySuccessLabel = (text, type) => {
6656
- const labelId = `success-${Date.now()}-${Math.random()}`;
6657
- setSuccessLabels((previousLabels) => [...previousLabels, {
6658
- id: labelId,
6659
- text
6660
- }]);
6661
- options.onSuccessLabel?.(text, type, {
6662
- x: mouseX(),
6663
- y: mouseY()
6664
- });
6665
- setTimeout(() => {
6666
- setSuccessLabels((previousLabels) => previousLabels.filter((label) => label.id !== labelId));
6667
- }, SUCCESS_LABEL_DURATION_MS);
6668
- };
6669
- const extractElementTagNameForSuccess = (element) => {
6670
- const tagName = extractElementTagName(element);
6671
- return tagName ? `<${tagName}>` : "1 element";
6672
- };
6673
6675
  const notifyElementsSelected = (elements) => {
6674
6676
  const elementsPayload = elements.map((element) => ({
6675
6677
  tagName: extractElementTagName(element)
@@ -6703,7 +6705,7 @@ https://react-grab.com`, `background: #330039; color: #ffffff; border: 1px solid
6703
6705
  const removeLabelInstance = (instanceId) => {
6704
6706
  setLabelInstances((prev) => prev.filter((instance) => instance.id !== instanceId));
6705
6707
  };
6706
- const executeCopyOperation = async (positionX, positionY, operation, bounds, tagName, componentName, element) => {
6708
+ const executeCopyOperation = async (positionX, positionY, operation, bounds, tagName, componentName, element, shouldDeactivateAfter) => {
6707
6709
  setCopyStartX(positionX);
6708
6710
  setCopyStartY(positionY);
6709
6711
  if (bounds) {
@@ -6717,6 +6719,7 @@ https://react-grab.com`, `background: #330039; color: #ffffff; border: 1px solid
6717
6719
  const instanceId = bounds && tagName ? createLabelInstance(bounds, tagName, componentName, "copying", element, positionX) : null;
6718
6720
  await operation().finally(() => {
6719
6721
  setIsCopying(false);
6722
+ setDidJustCopy(true);
6720
6723
  stopProgressAnimation();
6721
6724
  if (instanceId) {
6722
6725
  updateLabelInstance(instanceId, "copied");
@@ -6727,7 +6730,7 @@ https://react-grab.com`, `background: #330039; color: #ffffff; border: 1px solid
6727
6730
  }, 350);
6728
6731
  }, COPIED_LABEL_DURATION_MS);
6729
6732
  }
6730
- if (isToggleMode()) {
6733
+ if (isToggleMode() || shouldDeactivateAfter) {
6731
6734
  deactivateRenderer();
6732
6735
  }
6733
6736
  });
@@ -6790,16 +6793,12 @@ ${plainTextContentOnly}` : plainTextContentOnly;
6790
6793
  return didCopy;
6791
6794
  };
6792
6795
  const copySingleElementToClipboard = async (targetElement2, extraPrompt) => {
6793
- const successLabelType = extraPrompt ? "input-submit" : "copy";
6794
6796
  options.onElementSelect?.(targetElement2);
6795
6797
  if (theme().grabbedBoxes.enabled) {
6796
6798
  showTemporaryGrabbedBox(createElementBounds(targetElement2), targetElement2);
6797
6799
  }
6798
6800
  await new Promise((resolve) => requestAnimationFrame(resolve));
6799
- const didCopy = await tryCopyWithFallback([targetElement2], extraPrompt);
6800
- if (didCopy && theme().successLabels.enabled) {
6801
- showTemporarySuccessLabel(extractElementTagNameForSuccess(targetElement2), successLabelType);
6802
- }
6801
+ await tryCopyWithFallback([targetElement2], extraPrompt);
6803
6802
  notifyElementsSelected([targetElement2]);
6804
6803
  };
6805
6804
  const copyMultipleElementsToClipboard = async (targetElements) => {
@@ -6813,10 +6812,7 @@ ${plainTextContentOnly}` : plainTextContentOnly;
6813
6812
  }
6814
6813
  }
6815
6814
  await new Promise((resolve) => requestAnimationFrame(resolve));
6816
- const didCopy = await tryCopyWithFallback(targetElements);
6817
- if (didCopy && theme().successLabels.enabled) {
6818
- showTemporarySuccessLabel(`${targetElements.length} elements`, "copy");
6819
- }
6815
+ await tryCopyWithFallback(targetElements);
6820
6816
  notifyElementsSelected(targetElements);
6821
6817
  };
6822
6818
  const targetElement = createMemo(() => {
@@ -6895,8 +6891,8 @@ ${plainTextContentOnly}` : plainTextContentOnly;
6895
6891
  const copying = isCopying();
6896
6892
  if (!element) {
6897
6893
  return (() => {
6898
- var _el$ = _tmpl$17();
6899
- insert(_el$, copying ? "Please wait\u2026" : "1 element");
6894
+ var _el$ = _tmpl$18();
6895
+ insert(_el$, copying ? "Processing\u2026" : "1 element");
6900
6896
  return _el$;
6901
6897
  })();
6902
6898
  }
@@ -6921,8 +6917,8 @@ ${plainTextContentOnly}` : plainTextContentOnly;
6921
6917
  })();
6922
6918
  }
6923
6919
  return (() => {
6924
- var _el$10 = _tmpl$17();
6925
- insert(_el$10, copying ? "Please wait\u2026" : "1 element");
6920
+ var _el$10 = _tmpl$18();
6921
+ insert(_el$10, copying ? "Processing\u2026" : "1 element");
6926
6922
  return _el$10;
6927
6923
  })();
6928
6924
  });
@@ -6977,15 +6973,6 @@ ${plainTextContentOnly}` : plainTextContentOnly;
6977
6973
  clearSource();
6978
6974
  }).catch(clearSource);
6979
6975
  }));
6980
- createEffect(on(() => viewportVersion(), () => {
6981
- const currentBoxes = grabbedBoxes();
6982
- if (currentBoxes.length === 0) return;
6983
- const updatedBoxes = currentBoxes.map((box) => ({
6984
- ...box,
6985
- bounds: createElementBounds(box.element)
6986
- }));
6987
- setGrabbedBoxes(updatedBoxes);
6988
- }));
6989
6976
  createEffect(on(() => viewportVersion(), () => agentManager.updateSessionBoundsOnViewportChange()));
6990
6977
  createEffect(on(() => [isActivated(), isDragging(), isCopying(), isInputMode(), targetElement(), dragBounds()], ([active, dragging, copying, inputMode, target, drag]) => {
6991
6978
  options.onStateChange?.({
@@ -7125,6 +7112,7 @@ ${plainTextContentOnly}` : plainTextContentOnly;
7125
7112
  setIsInputExpanded(false);
7126
7113
  setFrozenElement(null);
7127
7114
  setSelectionLabelStatus("idle");
7115
+ setDidJustCopy(false);
7128
7116
  if (isDragging()) {
7129
7117
  setIsDragging(false);
7130
7118
  document.body.style.userSelect = "";
@@ -7179,6 +7167,7 @@ ${plainTextContentOnly}` : plainTextContentOnly;
7179
7167
  setMouseX(currentX);
7180
7168
  setMouseY(currentY);
7181
7169
  if (hasAgentProvider() && prompt) {
7170
+ elementInputCache.delete(element);
7182
7171
  deactivateRenderer();
7183
7172
  void agentManager.startSession({
7184
7173
  element,
@@ -7193,6 +7182,7 @@ ${plainTextContentOnly}` : plainTextContentOnly;
7193
7182
  }
7194
7183
  setIsInputMode(false);
7195
7184
  setInputText("");
7185
+ elementInputCache.delete(element);
7196
7186
  const tagName = extractElementTagName(element);
7197
7187
  void getNearestComponentName(element).then((componentName) => {
7198
7188
  void executeCopyOperation(currentX, currentY, () => copySingleElementToClipboard(element, prompt || void 0), bounds, tagName, componentName ?? void 0, element).then(() => {
@@ -7202,6 +7192,11 @@ ${plainTextContentOnly}` : plainTextContentOnly;
7202
7192
  };
7203
7193
  const handleInputCancel = () => {
7204
7194
  if (!isInputMode()) return;
7195
+ const element = frozenElement() || targetElement();
7196
+ const currentInput = inputText().trim();
7197
+ if (element && currentInput) {
7198
+ elementInputCache.set(element, currentInput);
7199
+ }
7205
7200
  deactivateRenderer();
7206
7201
  };
7207
7202
  const handleToggleExpand = () => {
@@ -7212,6 +7207,10 @@ ${plainTextContentOnly}` : plainTextContentOnly;
7212
7207
  setCopyStartX(mouseX());
7213
7208
  setCopyStartY(mouseY());
7214
7209
  setCopyOffsetFromCenterX(mouseX() - selectionCenterX);
7210
+ const cachedInput = elementInputCache.get(element);
7211
+ if (cachedInput) {
7212
+ setInputText(cachedInput);
7213
+ }
7215
7214
  }
7216
7215
  setIsToggleMode(true);
7217
7216
  setIsToggleFrozen(true);
@@ -7254,6 +7253,7 @@ ${plainTextContentOnly}` : plainTextContentOnly;
7254
7253
  };
7255
7254
  const handlePointerMove = (clientX, clientY) => {
7256
7255
  if (isInputMode() || isToggleFrozen()) return;
7256
+ setDidJustCopy(false);
7257
7257
  setMouseX(clientX);
7258
7258
  setMouseY(clientY);
7259
7259
  const now = performance.now();
@@ -7322,7 +7322,7 @@ ${plainTextContentOnly}` : plainTextContentOnly;
7322
7322
  setIsInputMode(true);
7323
7323
  } else {
7324
7324
  void getNearestComponentName(firstElement).then((componentName) => {
7325
- void executeCopyOperation(clientX, clientY, () => copyMultipleElementsToClipboard(selectedElements), bounds, tagName, componentName ?? void 0, firstElement);
7325
+ void executeCopyOperation(clientX, clientY, () => copyMultipleElementsToClipboard(selectedElements), bounds, tagName, componentName ?? void 0, firstElement, true);
7326
7326
  });
7327
7327
  }
7328
7328
  }
@@ -7339,8 +7339,64 @@ ${plainTextContentOnly}` : plainTextContentOnly;
7339
7339
  };
7340
7340
  const abortController = new AbortController();
7341
7341
  const eventListenerSignal = abortController.signal;
7342
+ const claimedEvents = /* @__PURE__ */ new WeakSet();
7343
+ const isEnterCode = (code) => code === "Enter" || code === "NumpadEnter";
7344
+ const originalKeyDescriptor = Object.getOwnPropertyDescriptor(KeyboardEvent.prototype, "key");
7345
+ let didPatchKeyboardEvent = false;
7346
+ if (originalKeyDescriptor?.get && !originalKeyDescriptor.get.__reactGrabPatched) {
7347
+ didPatchKeyboardEvent = true;
7348
+ const originalGetter = originalKeyDescriptor.get;
7349
+ const patchedGetter = function() {
7350
+ if (claimedEvents.has(this)) {
7351
+ return "";
7352
+ }
7353
+ return originalGetter.call(this);
7354
+ };
7355
+ patchedGetter.__reactGrabPatched = true;
7356
+ Object.defineProperty(KeyboardEvent.prototype, "key", {
7357
+ get: patchedGetter,
7358
+ configurable: true
7359
+ });
7360
+ }
7361
+ const blockEnterIfNeeded = (event) => {
7362
+ const originalKey = originalKeyDescriptor?.get ? originalKeyDescriptor.get.call(event) : event.key;
7363
+ const isEnterKey = originalKey === "Enter" || isEnterCode(event.code);
7364
+ const isOverlayActive = isActivated() || isHoldingKeys();
7365
+ const shouldBlockEnter = isEnterKey && isOverlayActive && !isInputMode();
7366
+ if (shouldBlockEnter) {
7367
+ claimedEvents.add(event);
7368
+ event.preventDefault();
7369
+ event.stopPropagation();
7370
+ event.stopImmediatePropagation();
7371
+ return true;
7372
+ }
7373
+ return false;
7374
+ };
7375
+ document.addEventListener("keydown", blockEnterIfNeeded, {
7376
+ signal: eventListenerSignal,
7377
+ capture: true
7378
+ });
7379
+ document.addEventListener("keyup", blockEnterIfNeeded, {
7380
+ signal: eventListenerSignal,
7381
+ capture: true
7382
+ });
7383
+ document.addEventListener("keypress", blockEnterIfNeeded, {
7384
+ signal: eventListenerSignal,
7385
+ capture: true
7386
+ });
7342
7387
  window.addEventListener("keydown", (event) => {
7343
- if (isInputMode() || isEventFromOverlay(event, "data-react-grab-ignore-events")) {
7388
+ blockEnterIfNeeded(event);
7389
+ const isEnterToActivateInput = isEnterCode(event.code) && isHoldingKeys() && !isInputMode();
7390
+ if (isInputMode() && isTargetKeyCombination(event, options)) {
7391
+ event.preventDefault();
7392
+ event.stopPropagation();
7393
+ setIsInputMode(false);
7394
+ setInputText("");
7395
+ setIsToggleFrozen(false);
7396
+ setIsInputExpanded(false);
7397
+ return;
7398
+ }
7399
+ if (isInputMode() || isEventFromOverlay(event, "data-react-grab-ignore-events") && !isEnterToActivateInput) {
7344
7400
  if (event.key === "Escape" && agentManager.isProcessing()) {
7345
7401
  agentManager.abortAllSessions();
7346
7402
  }
@@ -7356,9 +7412,10 @@ ${plainTextContentOnly}` : plainTextContentOnly;
7356
7412
  return;
7357
7413
  }
7358
7414
  }
7359
- if (event.key === "Enter" && isHoldingKeys() && !isInputMode()) {
7415
+ if (isEnterCode(event.code) && isHoldingKeys() && !isInputMode()) {
7360
7416
  event.preventDefault();
7361
7417
  event.stopPropagation();
7418
+ event.stopImmediatePropagation();
7362
7419
  const element = frozenElement() || targetElement();
7363
7420
  if (element) {
7364
7421
  const bounds = createElementBounds(element);
@@ -7366,6 +7423,10 @@ ${plainTextContentOnly}` : plainTextContentOnly;
7366
7423
  setCopyStartX(mouseX());
7367
7424
  setCopyStartY(mouseY());
7368
7425
  setCopyOffsetFromCenterX(mouseX() - selectionCenterX);
7426
+ const cachedInput = elementInputCache.get(element);
7427
+ if (cachedInput) {
7428
+ setInputText(cachedInput);
7429
+ }
7369
7430
  }
7370
7431
  setIsToggleMode(true);
7371
7432
  setIsToggleFrozen(true);
@@ -7403,16 +7464,20 @@ ${plainTextContentOnly}` : plainTextContentOnly;
7403
7464
  }
7404
7465
  if (!isTargetKeyCombination(event, options)) {
7405
7466
  if (isActivated() && !isToggleMode() && (event.metaKey || event.ctrlKey)) {
7406
- if (!MODIFIER_KEYS.includes(event.key) && event.key !== "Enter") {
7467
+ if (!MODIFIER_KEYS.includes(event.key) && !isEnterCode(event.code)) {
7407
7468
  deactivateRenderer();
7408
7469
  }
7409
7470
  }
7410
- if (event.key !== "Enter") {
7471
+ if (!isEnterCode(event.code) || !isHoldingKeys()) {
7411
7472
  return;
7412
7473
  }
7413
7474
  }
7414
7475
  if ((isActivated() || isHoldingKeys()) && !isInputMode()) {
7415
7476
  event.preventDefault();
7477
+ if (isEnterCode(event.code)) {
7478
+ event.stopPropagation();
7479
+ event.stopImmediatePropagation();
7480
+ }
7416
7481
  }
7417
7482
  if (isActivated()) {
7418
7483
  if (isToggleMode()) return;
@@ -7440,6 +7505,7 @@ ${plainTextContentOnly}` : plainTextContentOnly;
7440
7505
  capture: true
7441
7506
  });
7442
7507
  window.addEventListener("keyup", (event) => {
7508
+ if (blockEnterIfNeeded(event)) return;
7443
7509
  if (!isHoldingKeys() && !isActivated()) return;
7444
7510
  if (isInputMode()) return;
7445
7511
  const hasCustomShortcut = Boolean(options.activationShortcut || options.activationKey);
@@ -7486,6 +7552,10 @@ ${plainTextContentOnly}` : plainTextContentOnly;
7486
7552
  signal: eventListenerSignal,
7487
7553
  capture: true
7488
7554
  });
7555
+ window.addEventListener("keypress", blockEnterIfNeeded, {
7556
+ signal: eventListenerSignal,
7557
+ capture: true
7558
+ });
7489
7559
  window.addEventListener("mousemove", (event) => {
7490
7560
  setIsTouchMode(false);
7491
7561
  if (isEventFromOverlay(event, "data-react-grab-ignore-events")) return;
@@ -7494,6 +7564,7 @@ ${plainTextContentOnly}` : plainTextContentOnly;
7494
7564
  signal: eventListenerSignal
7495
7565
  });
7496
7566
  window.addEventListener("mousedown", (event) => {
7567
+ if (event.button !== 0) return;
7497
7568
  if (isEventFromOverlay(event, "data-react-grab-ignore-events")) return;
7498
7569
  if (isInputMode()) {
7499
7570
  handleInputCancel();
@@ -7509,14 +7580,16 @@ ${plainTextContentOnly}` : plainTextContentOnly;
7509
7580
  capture: true
7510
7581
  });
7511
7582
  window.addEventListener("pointerdown", (event) => {
7512
- if (!isRendererActive() || isCopying() || isInputMode()) return;
7583
+ if (event.button !== 0) return;
7513
7584
  if (isEventFromOverlay(event, "data-react-grab-ignore-events")) return;
7585
+ if (!isRendererActive() || isCopying() || isInputMode()) return;
7514
7586
  event.stopPropagation();
7515
7587
  }, {
7516
7588
  signal: eventListenerSignal,
7517
7589
  capture: true
7518
7590
  });
7519
7591
  window.addEventListener("mouseup", (event) => {
7592
+ if (event.button !== 0) return;
7520
7593
  handlePointerUp(event.clientX, event.clientY);
7521
7594
  }, {
7522
7595
  signal: eventListenerSignal
@@ -7594,6 +7667,10 @@ ${plainTextContentOnly}` : plainTextContentOnly;
7594
7667
  }, {
7595
7668
  signal: eventListenerSignal
7596
7669
  });
7670
+ const boundsRecalcIntervalId = setInterval(() => {
7671
+ setViewportVersion((version) => version + 1);
7672
+ }, BOUNDS_RECALC_INTERVAL_MS);
7673
+ onCleanup(() => clearInterval(boundsRecalcIntervalId));
7597
7674
  document.addEventListener("copy", (event) => {
7598
7675
  if (isInputMode() || isEventFromOverlay(event, "data-react-grab-ignore-events")) {
7599
7676
  return;
@@ -7626,6 +7703,7 @@ ${plainTextContentOnly}` : plainTextContentOnly;
7626
7703
  const range = currentSelection.getRangeAt(0);
7627
7704
  const rangeRect = range.getBoundingClientRect();
7628
7705
  if (rangeRect.width === 0 && rangeRect.height === 0) {
7706
+ clearNativeSelectionState();
7629
7707
  return;
7630
7708
  }
7631
7709
  const isBackward = (() => {
@@ -7637,6 +7715,7 @@ ${plainTextContentOnly}` : plainTextContentOnly;
7637
7715
  })();
7638
7716
  const clientRects = range.getClientRects();
7639
7717
  if (clientRects.length === 0) {
7718
+ clearNativeSelectionState();
7640
7719
  return;
7641
7720
  }
7642
7721
  const cursorRect = isBackward ? clientRects[0] : clientRects[clientRects.length - 1];
@@ -7646,15 +7725,15 @@ ${plainTextContentOnly}` : plainTextContentOnly;
7646
7725
  clearNativeSelectionState();
7647
7726
  return;
7648
7727
  }
7649
- setNativeSelectionCursorX(cursorX);
7650
- setNativeSelectionCursorY(cursorY);
7651
7728
  const container = range.commonAncestorContainer;
7652
7729
  const element = container.nodeType === Node.ELEMENT_NODE ? container : container.parentElement;
7653
7730
  if (element && isValidGrabbableElement(element)) {
7731
+ setNativeSelectionCursorX(cursorX);
7732
+ setNativeSelectionCursorY(cursorY);
7654
7733
  setNativeSelectionElements([element]);
7655
7734
  setHasNativeSelection(true);
7656
7735
  } else {
7657
- setNativeSelectionElements([]);
7736
+ clearNativeSelectionState();
7658
7737
  }
7659
7738
  }, 150);
7660
7739
  }, {
@@ -7668,10 +7747,14 @@ ${plainTextContentOnly}` : plainTextContentOnly;
7668
7747
  stopProgressAnimation();
7669
7748
  document.body.style.userSelect = "";
7670
7749
  setCursorOverride(null);
7750
+ if (didPatchKeyboardEvent && originalKeyDescriptor) {
7751
+ Object.defineProperty(KeyboardEvent.prototype, "key", originalKeyDescriptor);
7752
+ }
7671
7753
  });
7672
7754
  const rendererRoot = mountRoot(styles_default);
7673
7755
  const selectionVisible = createMemo(() => {
7674
7756
  if (!theme().selectionBox.enabled) return false;
7757
+ if (didJustCopy()) return false;
7675
7758
  return isRendererActive() && !isDragging() && Boolean(targetElement());
7676
7759
  });
7677
7760
  const selectionTagName = createMemo(() => {
@@ -7686,7 +7769,7 @@ ${plainTextContentOnly}` : plainTextContentOnly;
7686
7769
  });
7687
7770
  const selectionLabelVisible = createMemo(() => {
7688
7771
  if (!theme().elementLabel.enabled) return false;
7689
- if (successLabels().length > 0) return false;
7772
+ if (didJustCopy()) return false;
7690
7773
  return isRendererActive() && !isDragging() && Boolean(targetElement());
7691
7774
  });
7692
7775
  const computedLabelInstances = createMemo(() => {
@@ -7707,7 +7790,6 @@ ${plainTextContentOnly}` : plainTextContentOnly;
7707
7790
  if (!theme().elementLabel.enabled) return false;
7708
7791
  if (isInputMode()) return false;
7709
7792
  if (isCopying()) return true;
7710
- if (successLabels().length > 0) return false;
7711
7793
  return isRendererActive() && !isDragging() && Boolean(targetElement());
7712
7794
  });
7713
7795
  const crosshairVisible = createMemo(() => theme().crosshair.enabled && isRendererActive() && !isDragging() && !isTouchMode() && !isToggleFrozen());