react-grab 0.0.67 → 0.0.68
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.
- package/README.md +53 -3
- package/dist/{chunk-YPAQIOAG.js → chunk-6DG5DJMI.js} +216 -78
- package/dist/{chunk-IZU7ETT6.cjs → chunk-VMN6HO3J.cjs} +215 -78
- package/dist/{core-CZmmuMr9.d.cts → core-CnnkNbYQ.d.cts} +1 -85
- package/dist/{core-CZmmuMr9.d.ts → core-CnnkNbYQ.d.ts} +1 -85
- package/dist/core.cjs +7 -11
- package/dist/core.d.cts +1 -1
- package/dist/core.d.ts +1 -1
- package/dist/core.js +1 -1
- package/dist/index.cjs +8 -8
- package/dist/index.d.cts +2 -2
- package/dist/index.d.ts +2 -2
- package/dist/index.global.js +26 -26
- package/dist/index.js +2 -2
- package/dist/styles.css +1 -1
- package/package.json +1 -1
|
@@ -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\\/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\\/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}.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)}.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\\: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-\\[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}}`;
|
|
892
892
|
|
|
893
893
|
// src/utils/is-keyboard-event-triggered-by-input.ts
|
|
894
894
|
var FORM_TAGS_AND_ROLES = [
|
|
@@ -1029,7 +1029,12 @@ var ELEMENT_DETECTION_THROTTLE_MS = 32;
|
|
|
1029
1029
|
var AUTO_SCROLL_EDGE_THRESHOLD_PX = 25;
|
|
1030
1030
|
var AUTO_SCROLL_SPEED_PX = 10;
|
|
1031
1031
|
var Z_INDEX_LABEL = 2147483647;
|
|
1032
|
-
var MODIFIER_KEYS = [
|
|
1032
|
+
var MODIFIER_KEYS = [
|
|
1033
|
+
"Meta",
|
|
1034
|
+
"Control",
|
|
1035
|
+
"Shift",
|
|
1036
|
+
"Alt"
|
|
1037
|
+
];
|
|
1033
1038
|
var LOGO_SVG = `<svg width="294" height="294" viewBox="0 0 294 294" fill="none" xmlns="http://www.w3.org/2000/svg"><g clip-path="url(#clip0_0_3)"><mask id="mask0_0_3" style="mask-type:luminance" maskUnits="userSpaceOnUse" x="0" y="0" width="294" height="294"><path d="M294 0H0V294H294V0Z" fill="white"/></mask><g mask="url(#mask0_0_3)"><path d="M144.599 47.4924C169.712 27.3959 194.548 20.0265 212.132 30.1797C227.847 39.2555 234.881 60.3243 231.926 89.516C231.677 92.0069 231.328 94.5423 230.94 97.1058L228.526 110.14C228.517 110.136 228.505 110.132 228.495 110.127C228.486 110.165 228.479 110.203 228.468 110.24L216.255 105.741C216.256 105.736 216.248 105.728 216.248 105.723C207.915 103.125 199.421 101.075 190.82 99.5888L190.696 99.5588L173.526 97.2648L173.511 97.2631C173.492 97.236 173.467 97.2176 173.447 97.1905C163.862 96.2064 154.233 95.7166 144.599 95.7223C134.943 95.7162 125.295 96.219 115.693 97.2286C110.075 105.033 104.859 113.118 100.063 121.453C95.2426 129.798 90.8624 138.391 86.939 147.193C90.8624 155.996 95.2426 164.588 100.063 172.933C104.866 181.302 110.099 189.417 115.741 197.245C115.749 197.245 115.758 197.246 115.766 197.247L115.752 197.27L115.745 197.283L115.754 197.296L126.501 211.013L126.574 211.089C132.136 217.767 138.126 224.075 144.507 229.974L144.609 230.082L154.572 238.287C154.539 238.319 154.506 238.35 154.472 238.38C154.485 238.392 154.499 238.402 154.513 238.412L143.846 247.482L143.827 247.497C126.56 261.128 109.472 268.745 94.8019 268.745C88.5916 268.837 82.4687 267.272 77.0657 264.208C61.3496 255.132 54.3164 234.062 57.2707 204.871C57.528 202.307 57.8806 199.694 58.2904 197.054C28.3363 185.327 9.52301 167.51 9.52301 147.193C9.52301 129.042 24.2476 112.396 50.9901 100.375C53.3443 99.3163 55.7938 98.3058 58.2904 97.3526C57.8806 94.7023 57.528 92.0803 57.2707 89.516C54.3164 60.3243 61.3496 39.2555 77.0657 30.1797C94.6494 20.0265 119.486 27.3959 144.599 47.4924ZM70.6423 201.315C70.423 202.955 70.2229 204.566 70.0704 206.168C67.6686 229.567 72.5478 246.628 83.3615 252.988L83.5176 253.062C95.0399 259.717 114.015 254.426 134.782 238.38C125.298 229.45 116.594 219.725 108.764 209.314C95.8516 207.742 83.0977 205.066 70.6423 201.315ZM80.3534 163.438C77.34 171.677 74.8666 180.104 72.9484 188.664C81.1787 191.224 89.5657 193.247 98.0572 194.724L98.4618 194.813C95.2115 189.865 92.0191 184.66 88.9311 179.378C85.8433 174.097 83.003 168.768 80.3534 163.438ZM60.759 110.203C59.234 110.839 57.7378 111.475 56.27 112.11C34.7788 121.806 22.3891 134.591 22.3891 147.193C22.3891 160.493 36.4657 174.297 60.7494 184.26C63.7439 171.581 67.8124 159.182 72.9104 147.193C67.822 135.23 63.7566 122.855 60.759 110.203ZM98.4137 99.6404C89.8078 101.145 81.3075 103.206 72.9676 105.809C74.854 114.203 77.2741 122.468 80.2132 130.554L80.3059 130.939C82.9938 125.6 85.8049 120.338 88.8834 115.008C91.9618 109.679 95.1544 104.569 98.4137 99.6404ZM94.9258 38.5215C90.9331 38.4284 86.9866 39.3955 83.4891 41.3243C72.6291 47.6015 67.6975 64.5954 70.0424 87.9446L70.0416 88.2194C70.194 89.8208 70.3941 91.4325 70.6134 93.0624C83.0737 89.3364 95.8263 86.6703 108.736 85.0924C116.57 74.6779 125.28 64.9532 134.773 56.0249C119.877 44.5087 105.895 38.5215 94.9258 38.5215ZM205.737 41.3148C202.268 39.398 198.355 38.4308 194.394 38.5099L194.29 38.512C183.321 38.512 169.34 44.4991 154.444 56.0153C163.93 64.9374 172.634 74.6557 180.462 85.064C193.375 86.6345 206.128 89.3102 218.584 93.0624C218.812 91.4325 219.003 89.8118 219.165 88.2098C221.548 64.7099 216.65 47.6164 205.737 41.3148ZM144.552 64.3097C138.104 70.2614 132.054 76.6306 126.443 83.3765C132.39 82.995 138.426 82.8046 144.552 82.8046C150.727 82.8046 156.778 83.0143 162.707 83.3765C157.08 76.6293 151.015 70.2596 144.552 64.3097Z" fill="white"/><path d="M144.598 47.4924C169.712 27.3959 194.547 20.0265 212.131 30.1797C227.847 39.2555 234.88 60.3243 231.926 89.516C231.677 92.0069 231.327 94.5423 230.941 97.1058L228.526 110.14L228.496 110.127C228.487 110.165 228.478 110.203 228.469 110.24L216.255 105.741L216.249 105.723C207.916 103.125 199.42 101.075 190.82 99.5888L190.696 99.5588L173.525 97.2648L173.511 97.263C173.492 97.236 173.468 97.2176 173.447 97.1905C163.863 96.2064 154.234 95.7166 144.598 95.7223C134.943 95.7162 125.295 96.219 115.693 97.2286C110.075 105.033 104.859 113.118 100.063 121.453C95.2426 129.798 90.8622 138.391 86.939 147.193C90.8622 155.996 95.2426 164.588 100.063 172.933C104.866 181.302 110.099 189.417 115.741 197.245L115.766 197.247L115.752 197.27L115.745 197.283L115.754 197.296L126.501 211.013L126.574 211.089C132.136 217.767 138.126 224.075 144.506 229.974L144.61 230.082L154.572 238.287C154.539 238.319 154.506 238.35 154.473 238.38L154.512 238.412L143.847 247.482L143.827 247.497C126.56 261.13 109.472 268.745 94.8018 268.745C88.5915 268.837 82.4687 267.272 77.0657 264.208C61.3496 255.132 54.3162 234.062 57.2707 204.871C57.528 202.307 57.8806 199.694 58.2904 197.054C28.3362 185.327 9.52298 167.51 9.52298 147.193C9.52298 129.042 24.2476 112.396 50.9901 100.375C53.3443 99.3163 55.7938 98.3058 58.2904 97.3526C57.8806 94.7023 57.528 92.0803 57.2707 89.516C54.3162 60.3243 61.3496 39.2555 77.0657 30.1797C94.6493 20.0265 119.486 27.3959 144.598 47.4924ZM70.6422 201.315C70.423 202.955 70.2229 204.566 70.0704 206.168C67.6686 229.567 72.5478 246.628 83.3615 252.988L83.5175 253.062C95.0399 259.717 114.015 254.426 134.782 238.38C125.298 229.45 116.594 219.725 108.764 209.314C95.8515 207.742 83.0977 205.066 70.6422 201.315ZM80.3534 163.438C77.34 171.677 74.8666 180.104 72.9484 188.664C81.1786 191.224 89.5657 193.247 98.0572 194.724L98.4618 194.813C95.2115 189.865 92.0191 184.66 88.931 179.378C85.8433 174.097 83.003 168.768 80.3534 163.438ZM60.7589 110.203C59.234 110.839 57.7378 111.475 56.2699 112.11C34.7788 121.806 22.3891 134.591 22.3891 147.193C22.3891 160.493 36.4657 174.297 60.7494 184.26C63.7439 171.581 67.8124 159.182 72.9103 147.193C67.822 135.23 63.7566 122.855 60.7589 110.203ZM98.4137 99.6404C89.8078 101.145 81.3075 103.206 72.9676 105.809C74.8539 114.203 77.2741 122.468 80.2132 130.554L80.3059 130.939C82.9938 125.6 85.8049 120.338 88.8834 115.008C91.9618 109.679 95.1544 104.569 98.4137 99.6404ZM94.9258 38.5215C90.9331 38.4284 86.9866 39.3955 83.4891 41.3243C72.629 47.6015 67.6975 64.5954 70.0424 87.9446L70.0415 88.2194C70.194 89.8208 70.3941 91.4325 70.6134 93.0624C83.0737 89.3364 95.8262 86.6703 108.736 85.0924C116.57 74.6779 125.28 64.9532 134.772 56.0249C119.877 44.5087 105.895 38.5215 94.9258 38.5215ZM205.737 41.3148C202.268 39.398 198.355 38.4308 194.394 38.5099L194.291 38.512C183.321 38.512 169.34 44.4991 154.443 56.0153C163.929 64.9374 172.634 74.6557 180.462 85.064C193.374 86.6345 206.129 89.3102 218.584 93.0624C218.813 91.4325 219.003 89.8118 219.166 88.2098C221.548 64.7099 216.65 47.6164 205.737 41.3148ZM144.551 64.3097C138.103 70.2614 132.055 76.6306 126.443 83.3765C132.389 82.995 138.427 82.8046 144.551 82.8046C150.727 82.8046 156.779 83.0143 162.707 83.3765C157.079 76.6293 151.015 70.2596 144.551 64.3097Z" fill="#FF40E0"/></g><mask id="mask1_0_3" style="mask-type:luminance" maskUnits="userSpaceOnUse" x="102" y="84" width="161" height="162"><path d="M235.282 84.827L102.261 112.259L129.693 245.28L262.714 217.848L235.282 84.827Z" fill="white"/></mask><g mask="url(#mask1_0_3)"><path d="M136.863 129.916L213.258 141.224C220.669 142.322 222.495 152.179 215.967 155.856L187.592 171.843L184.135 204.227C183.339 211.678 173.564 213.901 169.624 207.526L129.021 141.831C125.503 136.14 130.245 128.936 136.863 129.916Z" fill="#FF40E0" stroke="#FF40E0" stroke-width="0.817337" stroke-linecap="round" stroke-linejoin="round"/></g></g><defs><clipPath id="clip0_0_3"><rect width="294" height="294" fill="white"/></clipPath></defs></svg>`;
|
|
1034
1039
|
|
|
1035
1040
|
// src/utils/lerp.ts
|
|
@@ -3734,6 +3739,81 @@ var Crosshair = (props) => {
|
|
|
3734
3739
|
});
|
|
3735
3740
|
};
|
|
3736
3741
|
|
|
3742
|
+
// src/utils/speech-recognition.ts
|
|
3743
|
+
var useSpeechRecognition = (options) => {
|
|
3744
|
+
let speechRecognition;
|
|
3745
|
+
const [isListening, setIsListening] = createSignal(false);
|
|
3746
|
+
const isSupported = () => typeof window !== "undefined" && (!!window.SpeechRecognition || !!window.webkitSpeechRecognition);
|
|
3747
|
+
const start = () => {
|
|
3748
|
+
if (!isSupported()) return;
|
|
3749
|
+
const SpeechRecognitionConstructor = window.SpeechRecognition || window.webkitSpeechRecognition;
|
|
3750
|
+
if (!SpeechRecognitionConstructor) return;
|
|
3751
|
+
speechRecognition = new SpeechRecognitionConstructor();
|
|
3752
|
+
speechRecognition.continuous = true;
|
|
3753
|
+
speechRecognition.interimResults = true;
|
|
3754
|
+
speechRecognition.lang = navigator.language || "en-US";
|
|
3755
|
+
let lastInterimText = "";
|
|
3756
|
+
let lastValueWeSet = "";
|
|
3757
|
+
speechRecognition.onresult = (event) => {
|
|
3758
|
+
const currentValue = options.getCurrentValue();
|
|
3759
|
+
let baseValue;
|
|
3760
|
+
if (lastInterimText && currentValue.endsWith(lastInterimText)) {
|
|
3761
|
+
baseValue = currentValue.slice(0, -lastInterimText.length);
|
|
3762
|
+
} else if (currentValue === lastValueWeSet) {
|
|
3763
|
+
baseValue = currentValue.slice(0, -lastInterimText.length);
|
|
3764
|
+
} else {
|
|
3765
|
+
baseValue = currentValue;
|
|
3766
|
+
}
|
|
3767
|
+
let finalText = "";
|
|
3768
|
+
let interimText = "";
|
|
3769
|
+
for (let i2 = event.resultIndex; i2 < event.results.length; i2++) {
|
|
3770
|
+
const transcript = event.results[i2][0].transcript;
|
|
3771
|
+
if (event.results[i2].isFinal) {
|
|
3772
|
+
finalText += transcript;
|
|
3773
|
+
} else {
|
|
3774
|
+
interimText += transcript;
|
|
3775
|
+
}
|
|
3776
|
+
}
|
|
3777
|
+
lastInterimText = interimText;
|
|
3778
|
+
const newValue = baseValue + finalText + interimText;
|
|
3779
|
+
lastValueWeSet = newValue;
|
|
3780
|
+
options.onTranscript(newValue);
|
|
3781
|
+
};
|
|
3782
|
+
speechRecognition.onerror = () => {
|
|
3783
|
+
setIsListening(false);
|
|
3784
|
+
};
|
|
3785
|
+
speechRecognition.onend = () => {
|
|
3786
|
+
setIsListening(false);
|
|
3787
|
+
};
|
|
3788
|
+
speechRecognition.start();
|
|
3789
|
+
setIsListening(true);
|
|
3790
|
+
};
|
|
3791
|
+
const stop2 = () => {
|
|
3792
|
+
if (speechRecognition) {
|
|
3793
|
+
speechRecognition.stop();
|
|
3794
|
+
speechRecognition = void 0;
|
|
3795
|
+
}
|
|
3796
|
+
setIsListening(false);
|
|
3797
|
+
};
|
|
3798
|
+
const toggle = () => {
|
|
3799
|
+
if (isListening()) {
|
|
3800
|
+
stop2();
|
|
3801
|
+
} else {
|
|
3802
|
+
start();
|
|
3803
|
+
}
|
|
3804
|
+
};
|
|
3805
|
+
onCleanup(() => {
|
|
3806
|
+
stop2();
|
|
3807
|
+
});
|
|
3808
|
+
return {
|
|
3809
|
+
isListening,
|
|
3810
|
+
isSupported,
|
|
3811
|
+
start,
|
|
3812
|
+
stop: stop2,
|
|
3813
|
+
toggle
|
|
3814
|
+
};
|
|
3815
|
+
};
|
|
3816
|
+
|
|
3737
3817
|
// src/components/icon-open.tsx
|
|
3738
3818
|
var _tmpl$3 = /* @__PURE__ */ template(`<svg xmlns=http://www.w3.org/2000/svg viewBox="0 0 24 24"fill=none stroke=currentColor stroke-linecap=round stroke-linejoin=round stroke-width=2><path d="M12 6H6a2 2 0 0 0-2 2v10a2 2 0 0 0 2 2h10a2 2 0 0 0 2-2v-6"></path><path d="M11 13l9-9"></path><path d="M15 4h5v5">`);
|
|
3739
3819
|
var IconOpen = (props) => {
|
|
@@ -3755,23 +3835,45 @@ var IconOpen = (props) => {
|
|
|
3755
3835
|
})();
|
|
3756
3836
|
};
|
|
3757
3837
|
|
|
3838
|
+
// src/components/icon-mic.tsx
|
|
3839
|
+
var _tmpl$4 = /* @__PURE__ */ template(`<svg xmlns=http://www.w3.org/2000/svg viewBox="0 0 24 24"fill=none stroke=currentColor stroke-width=2 stroke-linecap=round stroke-linejoin=round><path d="M12 2a3 3 0 0 0-3 3v7a3 3 0 0 0 6 0V5a3 3 0 0 0-3-3Z"></path><path d="M19 10v2a7 7 0 0 1-14 0v-2"></path><line x1=12 x2=12 y1=19 y2=22>`);
|
|
3840
|
+
var IconMic = (props) => {
|
|
3841
|
+
const size = () => props.size ?? 12;
|
|
3842
|
+
return (() => {
|
|
3843
|
+
var _el$ = _tmpl$4();
|
|
3844
|
+
createRenderEffect((_p$) => {
|
|
3845
|
+
var _v$ = size(), _v$2 = size(), _v$3 = props.class;
|
|
3846
|
+
_v$ !== _p$.e && setAttribute(_el$, "width", _p$.e = _v$);
|
|
3847
|
+
_v$2 !== _p$.t && setAttribute(_el$, "height", _p$.t = _v$2);
|
|
3848
|
+
_v$3 !== _p$.a && setAttribute(_el$, "class", _p$.a = _v$3);
|
|
3849
|
+
return _p$;
|
|
3850
|
+
}, {
|
|
3851
|
+
e: void 0,
|
|
3852
|
+
t: void 0,
|
|
3853
|
+
a: void 0
|
|
3854
|
+
});
|
|
3855
|
+
return _el$;
|
|
3856
|
+
})();
|
|
3857
|
+
};
|
|
3858
|
+
|
|
3758
3859
|
// src/components/selection-label.tsx
|
|
3759
|
-
var _tmpl$
|
|
3860
|
+
var _tmpl$5 = /* @__PURE__ */ template(`<div style="background-image:linear-gradient(in oklab 180deg, oklab(88.7% 0.086 -0.058) 0%, oklab(83.2% 0.132 -0.089) 100%)"><span>`);
|
|
3760
3861
|
var _tmpl$22 = /* @__PURE__ */ template(`<div class="contain-layout shrink-0 flex items-center w-fit h-4 rounded-[1px] gap-1 px-[3px] [border-width:0.5px] border-solid border-[#B3B3B3] py-0 bg-[#F7F7F7]"><span class="text-[#0C0C0C] text-[11.5px] leading-3.5 shrink-0 tracking-[-0.08em] font-[ui-monospace,'SFMono-Regular','SF_Mono','Menlo','Consolas','Liberation_Mono',monospace] w-fit h-fit">`);
|
|
3761
3862
|
var _tmpl$32 = /* @__PURE__ */ template(`<div class="contain-layout shrink-0 flex items-center w-fit h-4 rounded-[1px] gap-1 px-[3px] [border-width:0.5px] border-solid border-white py-0"><span class="text-[#0C0C0C] text-[11.5px] leading-3.5 shrink-0 tracking-[-0.08em] font-[ui-monospace,'SFMono-Regular','SF_Mono','Menlo','Consolas','Liberation_Mono',monospace] w-fit h-fit">>`);
|
|
3762
3863
|
var _tmpl$42 = /* @__PURE__ */ template(`<div class="absolute w-0 h-0"style="border-left:8px solid transparent;border-right:8px solid transparent">`);
|
|
3763
|
-
var _tmpl$
|
|
3864
|
+
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">`);
|
|
3764
3865
|
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%)">`);
|
|
3765
3866
|
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">`);
|
|
3766
3867
|
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">`);
|
|
3767
|
-
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"placeholder="type to edit"rows=1 disabled style=field-sizing:content;min-height:16px>`);
|
|
3868
|
+
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>`);
|
|
3768
3869
|
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">`);
|
|
3769
3870
|
var _tmpl$1 = /* @__PURE__ */ template(`<div class="contain-layout shrink-0 flex items-center gap-px w-fit h-fit">`);
|
|
3770
3871
|
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`);
|
|
3771
3872
|
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">`);
|
|
3772
|
-
var _tmpl$12 = /* @__PURE__ */ template(`<
|
|
3773
|
-
var _tmpl$13 = /* @__PURE__ */ template(`<div class="
|
|
3774
|
-
var _tmpl$14 = /* @__PURE__ */ template(`<div
|
|
3873
|
+
var _tmpl$12 = /* @__PURE__ */ template(`<button>`);
|
|
3874
|
+
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)>`);
|
|
3875
|
+
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">`);
|
|
3876
|
+
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">`);
|
|
3775
3877
|
var ARROW_HEIGHT = 8;
|
|
3776
3878
|
var LABEL_GAP = 4;
|
|
3777
3879
|
var IDLE_TIMEOUT_MS = 400;
|
|
@@ -3786,7 +3888,7 @@ var TagBadge = (props) => {
|
|
|
3786
3888
|
props.onHoverChange?.(false);
|
|
3787
3889
|
};
|
|
3788
3890
|
return (() => {
|
|
3789
|
-
var _el$ = _tmpl$
|
|
3891
|
+
var _el$ = _tmpl$5(), _el$2 = _el$.firstChild;
|
|
3790
3892
|
addEventListener(_el$, "click", props.onClick);
|
|
3791
3893
|
_el$.addEventListener("mouseleave", handleMouseLeave);
|
|
3792
3894
|
_el$.addEventListener("mouseenter", handleMouseEnter);
|
|
@@ -3851,7 +3953,7 @@ var ClickToCopyPill = (props) => {
|
|
|
3851
3953
|
return "Click to copy";
|
|
3852
3954
|
};
|
|
3853
3955
|
return (() => {
|
|
3854
|
-
var _el$7 = _tmpl$
|
|
3956
|
+
var _el$7 = _tmpl$52(), _el$8 = _el$7.firstChild;
|
|
3855
3957
|
addEventListener(_el$7, "click", props.onClick);
|
|
3856
3958
|
insert(_el$8, labelText);
|
|
3857
3959
|
createRenderEffect(() => className(_el$7, cn("contain-layout shrink-0 flex items-center px-0 py-px w-fit h-[18px] rounded-[1.5px] gap-[3px]", props.asButton && "cursor-pointer", props.dimmed && "opacity-50 hover:opacity-100 transition-opacity")));
|
|
@@ -3872,6 +3974,10 @@ var SelectionLabel = (props) => {
|
|
|
3872
3974
|
const [arrowPosition, setArrowPosition] = createSignal("bottom");
|
|
3873
3975
|
const [viewportVersion, setViewportVersion] = createSignal(0);
|
|
3874
3976
|
const [isIdle, setIsIdle] = createSignal(false);
|
|
3977
|
+
const speechRecognition = useSpeechRecognition({
|
|
3978
|
+
onTranscript: (transcript) => props.onInputChange?.(transcript),
|
|
3979
|
+
getCurrentValue: () => props.inputValue ?? ""
|
|
3980
|
+
});
|
|
3875
3981
|
const isNotProcessing = () => props.status !== "copying" && props.status !== "copied" && props.status !== "fading";
|
|
3876
3982
|
const measureContainer = () => {
|
|
3877
3983
|
if (containerRef && !isTagCurrentlyHovered) {
|
|
@@ -3900,6 +4006,7 @@ var SelectionLabel = (props) => {
|
|
|
3900
4006
|
if (event.code === "Enter" && isIdle() && !props.isInputExpanded && isNotProcessing()) {
|
|
3901
4007
|
event.preventDefault();
|
|
3902
4008
|
event.stopPropagation();
|
|
4009
|
+
event.stopImmediatePropagation();
|
|
3903
4010
|
props.onToggleExpand?.();
|
|
3904
4011
|
}
|
|
3905
4012
|
};
|
|
@@ -3940,6 +4047,8 @@ var SelectionLabel = (props) => {
|
|
|
3940
4047
|
setTimeout(() => {
|
|
3941
4048
|
inputRef?.focus();
|
|
3942
4049
|
}, 0);
|
|
4050
|
+
} else {
|
|
4051
|
+
speechRecognition.stop();
|
|
3943
4052
|
}
|
|
3944
4053
|
});
|
|
3945
4054
|
const computedPosition = () => {
|
|
@@ -3988,11 +4097,14 @@ var SelectionLabel = (props) => {
|
|
|
3988
4097
|
};
|
|
3989
4098
|
const handleKeyDown = (event) => {
|
|
3990
4099
|
event.stopPropagation();
|
|
4100
|
+
event.stopImmediatePropagation();
|
|
3991
4101
|
if (event.code === "Enter" && !event.shiftKey) {
|
|
3992
4102
|
event.preventDefault();
|
|
4103
|
+
speechRecognition.stop();
|
|
3993
4104
|
props.onSubmit?.();
|
|
3994
4105
|
} else if (event.code === "Escape") {
|
|
3995
4106
|
event.preventDefault();
|
|
4107
|
+
speechRecognition.stop();
|
|
3996
4108
|
props.onCancel?.();
|
|
3997
4109
|
}
|
|
3998
4110
|
};
|
|
@@ -4013,15 +4125,19 @@ var SelectionLabel = (props) => {
|
|
|
4013
4125
|
event.stopPropagation();
|
|
4014
4126
|
event.stopImmediatePropagation();
|
|
4015
4127
|
};
|
|
4016
|
-
const handleSubmit = () =>
|
|
4128
|
+
const handleSubmit = () => {
|
|
4129
|
+
speechRecognition.stop();
|
|
4130
|
+
props.onSubmit?.();
|
|
4131
|
+
};
|
|
4017
4132
|
return createComponent(Show, {
|
|
4018
4133
|
get when() {
|
|
4019
4134
|
return memo(() => props.visible !== false)() && props.selectionBounds;
|
|
4020
4135
|
},
|
|
4021
4136
|
get children() {
|
|
4022
|
-
var _el$0 = _tmpl$
|
|
4137
|
+
var _el$0 = _tmpl$15(), _el$12 = _el$0.firstChild;
|
|
4023
4138
|
_el$0.$$click = stopPropagation;
|
|
4024
4139
|
_el$0.$$mousedown = stopPropagation;
|
|
4140
|
+
_el$0.$$pointerdown = stopPropagation;
|
|
4025
4141
|
var _ref$ = containerRef;
|
|
4026
4142
|
typeof _ref$ === "function" ? use(_ref$, _el$0) : containerRef = _el$0;
|
|
4027
4143
|
insert(_el$0, createComponent(Arrow, {
|
|
@@ -4148,7 +4264,7 @@ var SelectionLabel = (props) => {
|
|
|
4148
4264
|
return memo(() => !!isNotProcessing())() && props.isInputExpanded;
|
|
4149
4265
|
},
|
|
4150
4266
|
get children() {
|
|
4151
|
-
var _el$29 = _tmpl$
|
|
4267
|
+
var _el$29 = _tmpl$14(), _el$30 = _el$29.firstChild;
|
|
4152
4268
|
insert(_el$30, createComponent(ClickToCopyPill, {
|
|
4153
4269
|
onClick: handleSubmit,
|
|
4154
4270
|
dimmed: true,
|
|
@@ -4210,13 +4326,46 @@ var SelectionLabel = (props) => {
|
|
|
4210
4326
|
}), null);
|
|
4211
4327
|
insert(_el$29, createComponent(BottomSection, {
|
|
4212
4328
|
get children() {
|
|
4213
|
-
var _el$32 = _tmpl$
|
|
4329
|
+
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;
|
|
4214
4330
|
_el$33.$$keydown = handleKeyDown;
|
|
4215
4331
|
_el$33.$$input = handleInput;
|
|
4216
4332
|
var _ref$3 = inputRef;
|
|
4217
4333
|
typeof _ref$3 === "function" ? use(_ref$3, _el$33) : inputRef = _el$33;
|
|
4218
|
-
_el$34
|
|
4219
|
-
|
|
4334
|
+
insert(_el$34, createComponent(Show, {
|
|
4335
|
+
get when() {
|
|
4336
|
+
return memo(() => !!props.hasAgent)() && speechRecognition.isSupported();
|
|
4337
|
+
},
|
|
4338
|
+
get children() {
|
|
4339
|
+
var _el$35 = _tmpl$12();
|
|
4340
|
+
addEventListener(_el$35, "click", speechRecognition.toggle);
|
|
4341
|
+
insert(_el$35, createComponent(IconMic, {
|
|
4342
|
+
size: 11,
|
|
4343
|
+
get ["class"]() {
|
|
4344
|
+
return speechRecognition.isListening() ? "animate-pulse" : "";
|
|
4345
|
+
}
|
|
4346
|
+
}));
|
|
4347
|
+
createRenderEffect((_p$) => {
|
|
4348
|
+
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";
|
|
4349
|
+
_v$3 !== _p$.e && className(_el$35, _p$.e = _v$3);
|
|
4350
|
+
_v$4 !== _p$.t && setAttribute(_el$35, "title", _p$.t = _v$4);
|
|
4351
|
+
return _p$;
|
|
4352
|
+
}, {
|
|
4353
|
+
e: void 0,
|
|
4354
|
+
t: void 0
|
|
4355
|
+
});
|
|
4356
|
+
return _el$35;
|
|
4357
|
+
}
|
|
4358
|
+
}), _el$36);
|
|
4359
|
+
_el$36.$$click = handleSubmit;
|
|
4360
|
+
createRenderEffect((_p$) => {
|
|
4361
|
+
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");
|
|
4362
|
+
_v$5 !== _p$.e && setAttribute(_el$33, "placeholder", _p$.e = _v$5);
|
|
4363
|
+
_v$6 !== _p$.t && className(_el$37, _p$.t = _v$6);
|
|
4364
|
+
return _p$;
|
|
4365
|
+
}, {
|
|
4366
|
+
e: void 0,
|
|
4367
|
+
t: void 0
|
|
4368
|
+
});
|
|
4220
4369
|
createRenderEffect(() => _el$33.value = props.inputValue ?? "");
|
|
4221
4370
|
return _el$32;
|
|
4222
4371
|
}
|
|
@@ -4225,12 +4374,12 @@ var SelectionLabel = (props) => {
|
|
|
4225
4374
|
}
|
|
4226
4375
|
}), null);
|
|
4227
4376
|
createRenderEffect((_p$) => {
|
|
4228
|
-
var _v$
|
|
4229
|
-
_v$
|
|
4230
|
-
_v$
|
|
4231
|
-
_v$
|
|
4232
|
-
_v$
|
|
4233
|
-
_v$
|
|
4377
|
+
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;
|
|
4378
|
+
_v$7 !== _p$.e && setStyleProperty(_el$0, "top", _p$.e = _v$7);
|
|
4379
|
+
_v$8 !== _p$.t && setStyleProperty(_el$0, "left", _p$.t = _v$8);
|
|
4380
|
+
_v$9 !== _p$.a && setStyleProperty(_el$0, "pointer-events", _p$.a = _v$9);
|
|
4381
|
+
_v$0 !== _p$.o && setStyleProperty(_el$0, "opacity", _p$.o = _v$0);
|
|
4382
|
+
_v$1 !== _p$.i && setStyleProperty(_el$12, "display", _p$.i = _v$1);
|
|
4234
4383
|
return _p$;
|
|
4235
4384
|
}, {
|
|
4236
4385
|
e: void 0,
|
|
@@ -4243,10 +4392,10 @@ var SelectionLabel = (props) => {
|
|
|
4243
4392
|
}
|
|
4244
4393
|
});
|
|
4245
4394
|
};
|
|
4246
|
-
delegateEvents(["click", "mousedown", "input", "keydown"]);
|
|
4395
|
+
delegateEvents(["click", "pointerdown", "mousedown", "input", "keydown"]);
|
|
4247
4396
|
|
|
4248
4397
|
// src/components/selection-cursor.tsx
|
|
4249
|
-
var _tmpl$
|
|
4398
|
+
var _tmpl$16 = /* @__PURE__ */ template(`<div class="fixed z-2147483647"><button data-react-grab-selection-cursor>`);
|
|
4250
4399
|
var SelectionCursor = (props) => {
|
|
4251
4400
|
const [isHovered, setIsHovered] = createSignal(false);
|
|
4252
4401
|
const [debouncedVisible, setDebouncedVisible] = createSignal(false);
|
|
@@ -4283,7 +4432,7 @@ var SelectionCursor = (props) => {
|
|
|
4283
4432
|
});
|
|
4284
4433
|
}
|
|
4285
4434
|
}), (() => {
|
|
4286
|
-
var _el$ = _tmpl$
|
|
4435
|
+
var _el$ = _tmpl$16(), _el$2 = _el$.firstChild;
|
|
4287
4436
|
_el$.addEventListener("mouseleave", () => setIsHovered(false));
|
|
4288
4437
|
_el$.addEventListener("mouseenter", () => setIsHovered(true));
|
|
4289
4438
|
_el$2.$$click = handleClick;
|
|
@@ -5470,14 +5619,6 @@ var getElementContext = async (element, options = {}) => {
|
|
|
5470
5619
|
}
|
|
5471
5620
|
return `${html}${stackContext.join("")}`;
|
|
5472
5621
|
};
|
|
5473
|
-
var getFileName = (stack) => {
|
|
5474
|
-
for (const frame of stack) {
|
|
5475
|
-
if (frame.fileName && je(frame.fileName)) {
|
|
5476
|
-
return $(frame.fileName);
|
|
5477
|
-
}
|
|
5478
|
-
}
|
|
5479
|
-
return null;
|
|
5480
|
-
};
|
|
5481
5622
|
var getHTMLPreview = (element) => {
|
|
5482
5623
|
const tagName = element.tagName.toLowerCase();
|
|
5483
5624
|
if (!(element instanceof HTMLElement)) {
|
|
@@ -5655,7 +5796,10 @@ var filterElementsInDrag = (dragRect, isValidGrabbableElement2, shouldCheckCover
|
|
|
5655
5796
|
bottom: elementRect.top + elementRect.height
|
|
5656
5797
|
};
|
|
5657
5798
|
if (shouldCheckCoverage) {
|
|
5658
|
-
const intersectionArea = calculateIntersectionArea(
|
|
5799
|
+
const intersectionArea = calculateIntersectionArea(
|
|
5800
|
+
dragBounds,
|
|
5801
|
+
elementBounds
|
|
5802
|
+
);
|
|
5659
5803
|
const elementArea = Math.max(0, elementRect.width * elementRect.height);
|
|
5660
5804
|
const hasMajorityCoverage = elementArea > 0 && intersectionArea / elementArea >= DRAG_COVERAGE_THRESHOLD;
|
|
5661
5805
|
if (hasMajorityCoverage) {
|
|
@@ -5677,12 +5821,20 @@ var removeNestedElements = (elements) => {
|
|
|
5677
5821
|
});
|
|
5678
5822
|
};
|
|
5679
5823
|
var getElementsInDrag = (dragRect, isValidGrabbableElement2) => {
|
|
5680
|
-
const elements = filterElementsInDrag(
|
|
5824
|
+
const elements = filterElementsInDrag(
|
|
5825
|
+
dragRect,
|
|
5826
|
+
isValidGrabbableElement2,
|
|
5827
|
+
true
|
|
5828
|
+
);
|
|
5681
5829
|
const uniqueElements = removeNestedElements(elements);
|
|
5682
5830
|
return uniqueElements;
|
|
5683
5831
|
};
|
|
5684
5832
|
var getElementsInDragLoose = (dragRect, isValidGrabbableElement2) => {
|
|
5685
|
-
const elements = filterElementsInDrag(
|
|
5833
|
+
const elements = filterElementsInDrag(
|
|
5834
|
+
dragRect,
|
|
5835
|
+
isValidGrabbableElement2,
|
|
5836
|
+
false
|
|
5837
|
+
);
|
|
5686
5838
|
const uniqueElements = removeNestedElements(elements);
|
|
5687
5839
|
return uniqueElements;
|
|
5688
5840
|
};
|
|
@@ -5848,7 +6000,9 @@ var isTargetKeyCombination = (event, options) => {
|
|
|
5848
6000
|
const shiftMatches = shiftKey ? event.shiftKey || event.key === "Shift" : true;
|
|
5849
6001
|
const altMatches = altKey ? event.altKey || event.key === "Alt" : true;
|
|
5850
6002
|
const allRequiredModifiersPressed = metaMatches && ctrlMatches && shiftMatches && altMatches;
|
|
5851
|
-
const requiredModifierCount = [metaKey, ctrlKey, shiftKey, altKey].filter(
|
|
6003
|
+
const requiredModifierCount = [metaKey, ctrlKey, shiftKey, altKey].filter(
|
|
6004
|
+
Boolean
|
|
6005
|
+
).length;
|
|
5852
6006
|
const pressedModifierCount = [
|
|
5853
6007
|
event.metaKey || event.key === "Meta",
|
|
5854
6008
|
event.ctrlKey || event.key === "Control",
|
|
@@ -5875,34 +6029,21 @@ var DEFAULT_THEME = {
|
|
|
5875
6029
|
enabled: true,
|
|
5876
6030
|
hue: 0,
|
|
5877
6031
|
selectionBox: {
|
|
5878
|
-
enabled: true
|
|
5879
|
-
color: void 0,
|
|
5880
|
-
borderRadius: void 0
|
|
6032
|
+
enabled: true
|
|
5881
6033
|
},
|
|
5882
6034
|
dragBox: {
|
|
5883
|
-
enabled: true
|
|
5884
|
-
color: void 0
|
|
6035
|
+
enabled: true
|
|
5885
6036
|
},
|
|
5886
6037
|
grabbedBoxes: {
|
|
5887
|
-
enabled: true
|
|
5888
|
-
color: void 0
|
|
6038
|
+
enabled: true
|
|
5889
6039
|
},
|
|
5890
6040
|
elementLabel: {
|
|
5891
|
-
enabled: true
|
|
5892
|
-
backgroundColor: void 0,
|
|
5893
|
-
textColor: void 0,
|
|
5894
|
-
borderColor: void 0,
|
|
5895
|
-
padding: void 0,
|
|
5896
|
-
cursorOffset: void 0
|
|
6041
|
+
enabled: true
|
|
5897
6042
|
},
|
|
5898
6043
|
successLabels: {
|
|
5899
6044
|
enabled: true
|
|
5900
6045
|
},
|
|
5901
6046
|
crosshair: {
|
|
5902
|
-
enabled: true,
|
|
5903
|
-
color: void 0
|
|
5904
|
-
},
|
|
5905
|
-
inputOverlay: {
|
|
5906
6047
|
enabled: true
|
|
5907
6048
|
}
|
|
5908
6049
|
};
|
|
@@ -5910,35 +6051,22 @@ var mergeThemeWithBase = (baseTheme, partialTheme) => ({
|
|
|
5910
6051
|
enabled: partialTheme.enabled ?? baseTheme.enabled,
|
|
5911
6052
|
hue: partialTheme.hue ?? baseTheme.hue,
|
|
5912
6053
|
selectionBox: {
|
|
5913
|
-
enabled: partialTheme.selectionBox?.enabled ?? baseTheme.selectionBox.enabled
|
|
5914
|
-
color: partialTheme.selectionBox?.color ?? baseTheme.selectionBox.color,
|
|
5915
|
-
borderRadius: partialTheme.selectionBox?.borderRadius ?? baseTheme.selectionBox.borderRadius
|
|
6054
|
+
enabled: partialTheme.selectionBox?.enabled ?? baseTheme.selectionBox.enabled
|
|
5916
6055
|
},
|
|
5917
6056
|
dragBox: {
|
|
5918
|
-
enabled: partialTheme.dragBox?.enabled ?? baseTheme.dragBox.enabled
|
|
5919
|
-
color: partialTheme.dragBox?.color ?? baseTheme.dragBox.color
|
|
6057
|
+
enabled: partialTheme.dragBox?.enabled ?? baseTheme.dragBox.enabled
|
|
5920
6058
|
},
|
|
5921
6059
|
grabbedBoxes: {
|
|
5922
|
-
enabled: partialTheme.grabbedBoxes?.enabled ?? baseTheme.grabbedBoxes.enabled
|
|
5923
|
-
color: partialTheme.grabbedBoxes?.color ?? baseTheme.grabbedBoxes.color
|
|
6060
|
+
enabled: partialTheme.grabbedBoxes?.enabled ?? baseTheme.grabbedBoxes.enabled
|
|
5924
6061
|
},
|
|
5925
6062
|
elementLabel: {
|
|
5926
|
-
enabled: partialTheme.elementLabel?.enabled ?? baseTheme.elementLabel.enabled
|
|
5927
|
-
backgroundColor: partialTheme.elementLabel?.backgroundColor ?? baseTheme.elementLabel.backgroundColor,
|
|
5928
|
-
textColor: partialTheme.elementLabel?.textColor ?? baseTheme.elementLabel.textColor,
|
|
5929
|
-
borderColor: partialTheme.elementLabel?.borderColor ?? baseTheme.elementLabel.borderColor,
|
|
5930
|
-
padding: partialTheme.elementLabel?.padding ?? baseTheme.elementLabel.padding,
|
|
5931
|
-
cursorOffset: partialTheme.elementLabel?.cursorOffset ?? baseTheme.elementLabel.cursorOffset
|
|
6063
|
+
enabled: partialTheme.elementLabel?.enabled ?? baseTheme.elementLabel.enabled
|
|
5932
6064
|
},
|
|
5933
6065
|
successLabels: {
|
|
5934
6066
|
enabled: partialTheme.successLabels?.enabled ?? baseTheme.successLabels.enabled
|
|
5935
6067
|
},
|
|
5936
6068
|
crosshair: {
|
|
5937
|
-
enabled: partialTheme.crosshair?.enabled ?? baseTheme.crosshair.enabled
|
|
5938
|
-
color: partialTheme.crosshair?.color ?? baseTheme.crosshair.color
|
|
5939
|
-
},
|
|
5940
|
-
inputOverlay: {
|
|
5941
|
-
enabled: partialTheme.inputOverlay?.enabled ?? baseTheme.inputOverlay.enabled
|
|
6069
|
+
enabled: partialTheme.crosshair?.enabled ?? baseTheme.crosshair.enabled
|
|
5942
6070
|
}
|
|
5943
6071
|
});
|
|
5944
6072
|
var mergeTheme = (userTheme) => userTheme ? mergeThemeWithBase(DEFAULT_THEME, userTheme) : DEFAULT_THEME;
|
|
@@ -6265,9 +6393,18 @@ var createAgentManager = (initialAgentOptions) => {
|
|
|
6265
6393
|
if (element && document.contains(element)) {
|
|
6266
6394
|
const newBounds = createElementBounds(element);
|
|
6267
6395
|
if (newBounds) {
|
|
6396
|
+
const oldBounds = session.selectionBounds;
|
|
6397
|
+
let updatedPosition = session.position;
|
|
6398
|
+
if (oldBounds) {
|
|
6399
|
+
const oldCenterX = oldBounds.x + oldBounds.width / 2;
|
|
6400
|
+
const offsetX = session.position.x - oldCenterX;
|
|
6401
|
+
const newCenterX = newBounds.x + newBounds.width / 2;
|
|
6402
|
+
updatedPosition = { ...session.position, x: newCenterX + offsetX };
|
|
6403
|
+
}
|
|
6268
6404
|
updatedSessions.set(sessionId, {
|
|
6269
6405
|
...session,
|
|
6270
|
-
selectionBounds: newBounds
|
|
6406
|
+
selectionBounds: newBounds,
|
|
6407
|
+
position: updatedPosition
|
|
6271
6408
|
});
|
|
6272
6409
|
didUpdate = true;
|
|
6273
6410
|
}
|
|
@@ -6295,7 +6432,7 @@ var createAgentManager = (initialAgentOptions) => {
|
|
|
6295
6432
|
};
|
|
6296
6433
|
|
|
6297
6434
|
// src/core.tsx
|
|
6298
|
-
var _tmpl$
|
|
6435
|
+
var _tmpl$17 = /* @__PURE__ */ template(`<span class="tabular-nums align-middle">`);
|
|
6299
6436
|
var _tmpl$23 = /* @__PURE__ */ template(`<span class="font-mono tabular-nums align-middle"><<!>>`);
|
|
6300
6437
|
var _tmpl$33 = /* @__PURE__ */ template(`<span class="tabular-nums ml-1 align-middle"> in `);
|
|
6301
6438
|
var onIdle = (callback) => {
|
|
@@ -6389,7 +6526,7 @@ var init = (rawOptions) => {
|
|
|
6389
6526
|
hasInited = true;
|
|
6390
6527
|
const logIntro = () => {
|
|
6391
6528
|
try {
|
|
6392
|
-
const version = "0.0.
|
|
6529
|
+
const version = "0.0.68";
|
|
6393
6530
|
const logoDataUri = `data:image/svg+xml;base64,${btoa(LOGO_SVG)}`;
|
|
6394
6531
|
console.log(`%cReact Grab${version ? ` v${version}` : ""}%c
|
|
6395
6532
|
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;`, "");
|
|
@@ -6759,7 +6896,7 @@ ${plainTextContentOnly}` : plainTextContentOnly;
|
|
|
6759
6896
|
const copying = isCopying();
|
|
6760
6897
|
if (!element) {
|
|
6761
6898
|
return (() => {
|
|
6762
|
-
var _el$ = _tmpl$
|
|
6899
|
+
var _el$ = _tmpl$17();
|
|
6763
6900
|
insert(_el$, copying ? "Please wait\u2026" : "1 element");
|
|
6764
6901
|
return _el$;
|
|
6765
6902
|
})();
|
|
@@ -6785,7 +6922,7 @@ ${plainTextContentOnly}` : plainTextContentOnly;
|
|
|
6785
6922
|
})();
|
|
6786
6923
|
}
|
|
6787
6924
|
return (() => {
|
|
6788
|
-
var _el$10 = _tmpl$
|
|
6925
|
+
var _el$10 = _tmpl$17();
|
|
6789
6926
|
insert(_el$10, copying ? "Please wait\u2026" : "1 element");
|
|
6790
6927
|
return _el$10;
|
|
6791
6928
|
})();
|
|
@@ -7366,6 +7503,7 @@ ${plainTextContentOnly}` : plainTextContentOnly;
|
|
|
7366
7503
|
const didHandle = handlePointerDown(event.clientX, event.clientY);
|
|
7367
7504
|
if (didHandle) {
|
|
7368
7505
|
event.preventDefault();
|
|
7506
|
+
event.stopPropagation();
|
|
7369
7507
|
}
|
|
7370
7508
|
}, {
|
|
7371
7509
|
signal: eventListenerSignal,
|
|
@@ -7814,4 +7952,4 @@ bippy/dist/index.js:
|
|
|
7814
7952
|
*)
|
|
7815
7953
|
*/
|
|
7816
7954
|
|
|
7817
|
-
export { DEFAULT_THEME, Ee, generateSnippet, getElementContext,
|
|
7955
|
+
export { DEFAULT_THEME, Ee, generateSnippet, getElementContext, getStack, init };
|